Skip to content
This repository has been archived by the owner on Jan 2, 2025. It is now read-only.

Commit

Permalink
🚸 Add .df() to Registry (#314)
Browse files Browse the repository at this point in the history
* 🚸 Add df to Registry

* πŸ’š Fix
  • Loading branch information
falexwolf authored Nov 20, 2023
1 parent a58c8ee commit d2d7934
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions lnschema_core/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,16 @@ def filter(cls, **expressions) -> "QuerySet":

return filter(cls, **expressions)

@classmethod
def df(cls) -> "pd.DataFrame":
"""Convert to `DataFrame`.
Warning: This will run a long time on large registries.
"""
from lamindb._filter import filter

return filter(cls).df()

@classmethod
def search(
cls,
Expand Down

0 comments on commit d2d7934

Please sign in to comment.