Read
quicat.read_dna(csv_path)
¶
This function reads the bulkDNA CSV file from the extract pipeline into a Polars DataFrame, extracts the specified columns as metadata, and creates a sparse matrix from the remaining columns. The resulting AnnData object is prepared with the metadata and count data.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
csv_path |
str
|
Path to the CSV file. |
required |
columns |
list of str
|
List of column names to extract as cell metadata. |
required |
Returns:
| Type | Description |
|---|---|
AnnData
|
anndata.AnnData: The constructed AnnData object with the sample metadata and count matrix. |
Source code in src/quicat/read/read_extract_output.py
quicat.read_sc(csv_path)
¶
This function reads the single-cell or spatial transcriptomics CSV file from the extract pipeline into a Polars DataFrame, extracts the specified columns as metadata, and creates a sparse matrix from the remaining columns. The resulting AnnData object is prepared with the metadata and expression data.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
csv_path |
str
|
Path to the CSV file. |
required |
columns |
list of str
|
List of column names to extract as cell metadata. |
required |
Returns:
| Type | Description |
|---|---|
AnnData
|
anndata.AnnData: The constructed AnnData object with the cell/spot metadata and expression matrix. |