Metadata-Version: 2.1
Name: pandas-sans-lambdas
Version: 0.1.0
Summary: Tools to simplify pandas-based data processing
Author-email: Jake Antmann <jakeantmann@gmail.com>
Maintainer-email: Jake Antmann <jakeantmann@gmail.com>
License: MIT License
        
        Copyright (c) 2022 Jake Antmann
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
        
Project-URL: homepage, https://github.com/jakeantmann/pandas_sans_lambdas
Project-URL: repository, https://github.com//jakeantmann/pandas_sans_lambdas
Project-URL: releases, https://github.com//jakeantmann/pandas_sans_lambdas/releases
Project-URL: issues, https://github.com/jakeantmann/pandas_sans_lambdas/issues
Project-URL: discussions, https://github.com/jakeantmann/pandas_sans_lambdas/discussions
Keywords: pandas
Classifier: Development Status :: 1 - Planning
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Framework :: Pytest
Classifier: Framework :: tox
Classifier: Framework :: Sphinx
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3 :: Only
Requires-Python: >=3.6
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pandas (>=1.5.0)
Requires-Dist: numpy (>=1.23.4)
Provides-Extra: tests
Requires-Dist: coverage (==6.3.2) ; extra == 'tests'
Requires-Dist: pytest (==7.1.3) ; extra == 'tests'
Requires-Dist: pytest-cov (==3.0.0) ; extra == 'tests'

# Pandas Sans Lambdas

![Tests](https://github.com/jakeantmann/pandas_sans_lambdas/actions/workflows/tests.yml/badge.svg)

Pandas method chaining using `assign` or `loc` usually means using lambdas. These get repetitive and reduce readability. Pandas Sans Lambdas is a solution to this. Here's an example:

``` python
import pandas as pd
from pandas_sans_lambdas import col

df = pd.DataFrame({"a": [1,2,3], "b": [4,5,6]})

# The old way
df = df.assign(with_lambdas = lambda DF: DF["a"] ** 2 / DF["b"])

# The new way
df = df.assign(with_lambdas = col("a") ** 2 / col("b"))

print(df)
```

Hopefully you agree that this is more readable!

## Current project status

This package is under development. Specifically, unit test coverage is currently incomplete. Get in touch if you want to contribute to test coverage, or if you find any bugs!
