spatialtis.NCD_marker#
- spatialtis.NCD_marker(data, selected_markers=None, importance_cutoff=0.5, layer_key=None, tree_kwargs=None, test_method='mannwhitneyu', pval=0.01, export_key='ncd_marker', **kwargs)[source]#
Identify neighbor cells dependent marker
This method tells you the dependency between markers and its neighbor cell type. The dependency is calculated by building a gradiant boosting tree (in here lightgbm) to determine the feature importance. A statistic test and fold change will be calculated for importance markers and its neighbor cells, the fold change is between marker with cell type at / not at the neighborhood.
- Parameters
- dataAnnData
The AnnData to work with.
- importance_cutofffloat, default: 0.5
Threshold to determine the feature markers.
- selected_markerslist of str
Select your interested markers.
- layer_keystr
The layer in AnnData to perform analysis.
- tree_kwargsdict
The keyword arguments that pass to the boosting tree class, (Default: n_jobs=-1, random_state=0).
- test_methodstr, default: ‘mannwhitneyu’
which test method to use, anything from scipy.stats.
- pvalfloat
The p-value threshold to determine significance.
- export_keystr
The key used to store result.
- **kwargs
Config for the analysis, for details check
spatialtis.abc.AnalysisBase
.