SC2Spa.sva.PrioritizeLPG

SC2Spa.sva.PrioritizeLPG(adata, Model, sparse=True, polar=True, CT=None, CT_field='MCT', percent=0.5, scale_factor=1000.0, Norm=False)

Prioritize genes’ contribution to location prediction

Run tl.Self_Mapping first to set Norm as True

Importance scores will be saved in adata.obs

Parameters

adata

Reference anndata object. Gene exprestlon matrix should be the shape of (cell, gene). Spatial information should be stored in adata.obsm[‘spatial’]

Model

A neural network trained utlng adata.X and adata.obsm[‘spatial’]

sparse

if gene exprestlon is saved in sparse format

CT
The cell type name used to normalize the importance score.

it must be one category in adata.obs[CT_field] This parameter is for normalization

polar

Transform cartetlan coordinates to polar coordinates if True. This parameter is for normalization

percent

The percentage of nodes selected for each layer

scale_factor

The factor used to scale the importance scores

Returns