You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have checked that this issue has not already been reported.
I have confirmed this bug exists on the latest version of anndata.
(optional) I have confirmed this bug exists on the master branch of anndata.
Report
Problem:
I create an AnnCollection without harmonization and then want to access some categorical obs column, e.g. disease (example below) or cell_type. Indexing cells from one anndata object and then accessing the attribute works as expected (returns categorical pd.Series). However, if cells are indexed from multiple anndata objects then accessing the attribute returns a numpy array with dtype=object. Looking at the source code the problem seems to lie in the concat_arrays function that does not have a logic for handling pd.Series arrays:
This issue has been automatically marked as stale because it has not had recent activity.
Please add a comment if you want to keep the issue open. Thank you for your contributions!
Please make sure these conditions are met
Report
Problem:
I create an AnnCollection without harmonization and then want to access some categorical obs column, e.g.
disease
(example below) orcell_type
. Indexing cells from one anndata object and then accessing the attribute works as expected (returns categorical pd.Series). However, if cells are indexed from multiple anndata objects then accessing the attribute returns a numpy array withdtype=object
. Looking at the source code the problem seems to lie in theconcat_arrays
function that does not have a logic for handling pd.Series arrays:anndata/anndata/_core/merge.py
Line 746 in c790113
Code:
Versions
The text was updated successfully, but these errors were encountered: