in
1 import giniclust3 as gc
2 gc.gini.calGini(adata) ###Calculate Gini Index
----> 3 adataGini=gc.gini.clusterGini(adata,neighbors=3) ###Cluster based on Gini Index
~/anaconda1907/lib/python3.7/site-packages/giniclust3/gini.py in clusterGini(adataSC, **kwargs)
231 raise SystemExit("Only leiden or louvain cluster method is allowed in this step.")
232 adataGini=adataSC[:,adataSC.var['gini']]
--> 233 scaleMatrix=arctanTransform((adataGini.X))
234 adataScaleGini=anndata.AnnData(X=scaleMatrix)
235
~/anaconda1907/lib/python3.7/site-packages/giniclust3/gini.py in arctanTransform(matrix)
63 expM=np.mean(expSort[0:end])
64 break
---> 65 arctan=np.arctan((transMatrix[i]-expM))*10+np.arctan(expM)*10
66 arctanExp.append(arctan)
67 arctanExp=np.array(arctanExp)
ValueError: operands could not be broadcast together with shapes (1219,) (0,)
Hi, I met these errors while calculating gini index, can you help me figure out why? thanks.
Hi, thanks for your interest for GiniClust3.
Could I know what's the dimension of your input scRNA data? Did you do the filter and normalization for your dataset?
ValueError Traceback (most recent call last)