Metadata-Version: 2.4
Name: sercol
Version: 1.0.5
Summary: Rich collection class with grouping and filtering helpers
Author-email: Alex Rubinsteyn <alex.rubinsteyn@unc.edu>
Project-URL: Homepage, https://github.com/openvax/sercol
Project-URL: Bug Tracker, https://github.com/openvax/sercol/issues
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Console
Classifier: Operating System :: OS Independent
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: serializable<2.0.0,>=1.0.0
Requires-Dist: pandas<4.0.0,>=2.0.0
Dynamic: license-file

[![Tests](https://github.com/openvax/sercol/actions/workflows/tests.yml/badge.svg)](https://github.com/openvax/sercol/actions/workflows/tests.yml)
<a href="https://coveralls.io/github/openvax/sercol?branch=master">
    <img src="https://coveralls.io/repos/openvax/sercol/badge.svg?branch=master&service=github" alt="Coverage Status" />
</a>
<a href="https://pypi.python.org/pypi/sercol/">
    <img src="https://img.shields.io/pypi/v/sercol.svg?maxAge=1000" alt="PyPI" />
</a>

# sercol

Filter and group a collection while keeping its collection type and source
metadata. `Collection` is the base class for `varcode.VariantCollection`,
`varcode.EffectCollection` and `mhctools.BindingPredictionCollection`.

## Install and filter

```sh
python -m pip install sercol
```

Python 3.11 or later is required.

```python
from sercol import Collection

values = Collection([5, 2, 3, 2])
print(list(values.filter(lambda value: value >= 3)))
# [5, 3]
```

## Documentation

- [Group values, save and reload](docs/index.md)
- [Select, order and track values](docs/guides/collections.md)
- [API reference](docs/reference.md)

To build the documentation locally, run
`python -m pip install -r requirements-docs.txt` and `./docs.sh`.
