BiomedicalMachineLearning / stLearn

A novel machine learning pipeline to analyse spatial transcriptomics data
Other
176 stars 23 forks source link

Question about st.spatial.trajectory.compare_transitions #286

Open zyy23 opened 3 months ago

zyy23 commented 3 months ago

Dear Author. I'm using

b=[1,2]
st.spatial.trajectory.pseudotimespace_global(adata_SME, use_label="leiden", list_clusters=b)
and
a=[0,2]
st.spatial.trajectory.pseudotimespace_global(adata_SME, use_label="leiden", list_clusters=a) 

did the trajectory analysis, can I use st.spatial.trajectory.compare _transitions() to compare the differences between these two for different clades? Thanks!

duypham2108 commented 3 months ago

Yes, I can do it. It just compares the genes between the two sets of transition markers. You still need to run st.spatial.trajectory.detect_transition_markers_clades. The transition markers result for each clade will be stored in adata.uns['clade name']. Then the st.spatial.trajectory.compare _transitions() function will compare between them