Open zsfrbkv opened 10 months ago
Seems that something wrong with the version.
I changed the code in init.py line 553
ef merge_cluster(ad, old_id, new_id, groups):
ad.obs[new_id] = ad.obs[old_id]
ad.obs[new_id] = ad.obs[new_id].astype('category')
print(ad.obs[new_id],make_unique(groups.astype(str)))
ad.obs[new_id] = ad.obs[new_id].cat.rename_categories(make_unique(groups.astype(str))) # **my change**
print(ad.obs[new_id],make_unique(groups.astype(str)))
# ad.obs[new_id].cat.categories = make_unique(groups.astype(str)) # **the original code**
ad.obs[new_id] = ad.obs[new_id].str.split('_').str[0]
return ad
I am not sure about if it's true, but it works.
P.S There result is not good. From my aspect.
Hi!
I was trying to use your package on a pre-clustered anndata object as described in your manual.
and I get the following output with an error:
Thank you for your help!