read_obs#
- @staticmethodSingleCell.read_obs(h5ad_file, *, columns=None, num_threads=-1)[source]#
Load just obs from an .h5ad file as a polars DataFrame.
- Parameters:
h5ad_file: File | str | Path
an .h5ad filename
columns: str | Iterable[str] | None
the column(s) of obs to load; if None, load all columns
num_threads: int
the number of threads to use when reading. By default (num_threads=-1), use all available cores, as determined by
os.cpu_count().
- Returns:
A polars DataFrame of the data in obs.
- Return type:
DataFrame