Skip to content

Commit

Permalink
Merge pull request #16 from srivarra/ops/groupby
Browse files Browse the repository at this point in the history
  • Loading branch information
srivarra authored Dec 21, 2024
2 parents e5a1422 + 4c702de commit af260dc
Show file tree
Hide file tree
Showing 27 changed files with 1,416 additions and 1,606 deletions.
8 changes: 4 additions & 4 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Bug report
description: Report something that is broken or incorrect
labels: bug
labels: [bug]
body:
- type: markdown
attributes:
Expand Down Expand Up @@ -28,13 +28,13 @@ body:
Please paste below the output of
```python
import session_info
session_info.show(html=False, dependencies=True)
import session_info2
session_info2.show(html=False, dependencies=True)
```
placeholder: |
-----
anndata 0.8.0rc2.dev27+ge524389
session_info 1.0.0
session_info2 0.0.1
-----
asttokens NA
awkward 1.8.0
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,9 @@ jobs:
uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v5.0.1
with:
python-version: ${{ matrix.python-version }}
enable-cache: true
cache-dependency-glob: "uv.lock"
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,9 @@ jobs:
fetch-depth: 0

- name: Install uv
uses: astral-sh/setup-uv@v3
uses: astral-sh/setup-uv@v5.0.1
with:
python-version: ${{ matrix.python-version }}
enable-cache: true
cache-dependency-glob: "uv.lock"
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
28 changes: 20 additions & 8 deletions docs/api/core.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,34 @@
# Core

```{eval-rst}
.. module:: annsel.core
.. module:: annsel.core.expr
```

```{eval-rst}
.. currentmodule:: annsel
```

## Selectors
## Selectors and Expressions

```{eval-rst}
.. autosummary::
:toctree: ../generated
:toctree: ../generated/
obs_col
obs_names
var_col
var_names
x
obs_names
var_names
col
```

## Types

```{eval-rst}
.. currentmodule:: annsel.core.typing
.. autosummary::
:toctree: ../generated/
Predicates
IntoExpr
SinglePredicate
PredicatesCollection
```
7 changes: 5 additions & 2 deletions docs/api/tools.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
.. currentmodule:: annsel
```

## Accessor: `an`
## AnnData Accessor: `an`

In order to use the `an` accessor, you need to import `annsel`.
In order to use the `AnnData` `an` accessor, you need to import `annsel`.

Something like the following:

Expand All @@ -24,12 +24,15 @@ or
import annsel as an
```

This will register the `an` accessor to the `AnnData` object.

```{eval-rst}
.. autosummary::
:toctree: ../generated
:template: autosummary/accessor_method.rst
AnnselAccessor.filter
AnnselAccessor.select
AnnselAccessor.group_by
AnnselAccessor.pipe
```
16 changes: 10 additions & 6 deletions docs/badges.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<div align="center">

| | |
| :---------: | :-------------------------------------------------------------------------------------------------------------------------------------------------------: |
| **Status** | [![Build][badge-build]][link-build] [![Tests][badge-test]][link-test] [![Documentation][badge-docs]][link-docs] [![codecov][badge-codecov]][link-codecov] |
| **Meta** | [![Hatch project][badge-hatch]][link-hatch] [![Ruff][badge-ruff]][link-ruff] [![uv][badge-uv]][link-uv] [![License][badge-license]][link-license] |
| **Package** | [![PyPI][badge-pypi]][link-pypi] [![PyPI][badge-python-versions]][link-pypi] |
| | |
| | |
| :---------: | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: |
| **Status** | [![Build][badge-build]][link-build] [![Tests][badge-test]][link-test] [![Documentation][badge-docs]][link-docs] [![codecov][badge-codecov]][link-codecov] [![pre-commit][badge-pre-commit]][link-pre-commit] |
| **Meta** | [![Hatch project][badge-hatch]][link-hatch] [![Ruff][badge-ruff]][link-ruff] [![uv][badge-uv]][link-uv] [![License][badge-license]][link-license] [![gitmoji][badge-gitmoji]][link-gitmoji] |
| **Package** | [![PyPI][badge-pypi]][link-pypi] [![PyPI][badge-python-versions]][link-pypi] |
| | |

</div>

Expand All @@ -19,6 +19,8 @@
[badge-hatch]: https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg
[badge-pypi]: https://img.shields.io/pypi/v/annsel.svg?logo=pypi&label=PyPI&logoColor=gold
[badge-python-versions]: https://img.shields.io/pypi/pyversions/annsel.svg?logo=python&label=Python&logoColor=gold
[badge-pre-commit]: https://results.pre-commit.ci/badge/github/srivarra/annsel/main.svg
[badge-gitmoji]: https://img.shields.io/badge/gitmoji-😜😍-FFDD67.svg
[scverse-discourse]: https://discourse.scverse.org/
[issue-tracker]: https://github.com/srivarra/annsel/issues
[changelog]: https://annsel.readthedocs.io/latest/changelog.html
Expand All @@ -34,3 +36,5 @@
[link-hatch]: https://github.com/pypa/hatch
[link-narwhals]: https://github.com/narwhals-dev/narwhals
[link-disucssions]: https://github.com/srivarra/annsel/discussions
[link-pre-commit]: https://results.pre-commit.ci/latest/github/srivarra/annsel/main
[link-gitmoji]: https://gitmoji.dev/
4 changes: 2 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
info = metadata("annsel")
project_name = info["Name"]
author = info["Author"]
copyright = f"{datetime.now():%Y}, {author}."
copyright = f"{datetime.now():%Y}, {author}"
version = info["Version"]
urls = dict(pu.split(", ") for pu in info.get_all("Project-URL"))
repository_url = urls["Source"]
Expand Down Expand Up @@ -74,7 +74,7 @@
napoleon_google_docstring = False
napoleon_numpy_docstring = True
napoleon_include_init_with_doc = False
napoleon_use_rtype = True # having a separate entry generally helps readability
napoleon_use_rtype = True # having a separate entry generally helps readaibteility
napoleon_use_param = True
myst_heading_anchors = 6 # create anchors for h1-h6
myst_enable_extensions = [
Expand Down
28 changes: 14 additions & 14 deletions docs/landing.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,25 +43,25 @@ There are several alternative options to install `annsel`:

1. Install the most recent release:

:::::{tabs}
::::{group-tab} uv
If you are using `uv`
:::::{tabs}
::::{group-tab} uv
If you are using `uv`

```zsh
uv add annsel
```
```zsh
uv add annsel
```

::::
::::

::::{group-tab} Pip
If you are using `pip`:
::::{group-tab} Pip
If you are using `pip`:

```zsh
pip install annsel
```
```zsh
pip install annsel
```

::::
:::::
::::
:::::

2. Install the latest development version:

Expand Down
Loading

0 comments on commit af260dc

Please sign in to comment.