scFates.pl.trends¶
- scFates.pl.trends(adata, features=None, cluster=None, highlight_features='A', n_features=10, root_milestone=None, milestones=None, module=None, branch=None, annot=None, title='', feature_cmap='RdBu_r', pseudo_cmap='viridis', plot_emb=True, plot_heatmap=True, wspace=None, show_segs=True, basis=None, heatmap_space=0.5, offset_names=0.15, fontsize=9, style='normal', ordering='pearson', ord_thre=0.7, figsize=None, axemb=None, show=None, output_mean=False, save=None, return_genes=None, **kwargs)¶
Plot a set of fitted features over pseudotime.
- Parameters
- adata :
AnnData
Annotated data matrix.
- features
Name of the fitted features.
- highlight_features :
List
| {‘A’, ‘fdr’}Union
[List
,Literal
[‘A’, ‘fdr’]] (default:'A'
) which features will be annotated on the heatmap, by default, features with highest amplitude are shown.
- n_features :
int
(default:10
) number of top features to show if no list are provided.
- root_milestone :
str
|None
Optional
[str
] (default:None
) tip defining progenitor branch.
- milestones :
str
|None
Optional
[str
] (default:None
) tips defining the progenies branches.
- module :
None
| {‘early’, ‘late’}Optional
[Literal
[‘early’, ‘late’]] (default:None
) if bifurcation analysis as been performed, subset features to a specific module.
- branch :
str
|None
Optional
[str
] (default:None
) if bifurcation analysis as been performed, subset features to a specific milestone.
- annot :
str
|None
Optional
[str
] (default:None
) adds an annotation row on top of the heatmap.
- title :
str
(default:''
) add a title.
- feature_cmap :
str
(default:'RdBu_r'
) colormap for features.
- pseudo_cmap :
str
(default:'viridis'
) colormap for pseudotime.
- plot_emb :
bool
(default:True
) call pl.trajectory on the left side.
- plot_heatmap :
bool
(default:True
) show heatmap on the right side.
- wspace :
float
|None
Optional
[float
] (default:None
) width space between emb and heatmap.
- show_segs :
bool
(default:True
) display segments on emb.
- basis :
str
|None
Optional
[str
] (default:None
) Name of the obsm basis to use if plot_emb is True.
- heatmap_space :
float
(default:0.5
) how much space does the heatmap take, in proportion of the whole plot space.
- offset_names :
float
(default:0.15
) how far on the right the annotated features should be displayed, in proportion of the heatmap space.
- fontsize :
int
(default:9
) font size of the feature annotations.
- style : {‘normal’, ‘italic’, ‘oblique’}
Literal
[‘normal’, ‘italic’, ‘oblique’] (default:'normal'
) font style.
- ordering :
None
| {‘pearson’, ‘spearman’, ‘quantile’, ‘max’}Optional
[Literal
[‘pearson’, ‘spearman’, ‘quantile’, ‘max’]] (default:'pearson'
) strategy to order the features on heatmap, quantile takes the mean pseudotime of the choosen value.
- ord_thre
for ‘max’: proportion of maximum of fitted value to consider to compute the mean pseudotime. for ‘quantile’: quantile to consider to compute the mean pseudotime. for ‘pearson’/’spearman’: proportion of max value to assign starting cell.
- figsize :
None
|tuple
Optional
[tuple
] (default:None
) figure size.
- axemb
existing ax for plotting emb
- output_mean :
bool
(default:False
) output mean fitted values to adata.
- show :
bool
|None
Optional
[bool
] (default:None
) show the plot.
- save :
str
|bool
|None
Union
[str
,bool
,None
] (default:None
) save the plot.
- return_genes :
bool
|None
Optional
[bool
] (default:None
) return list of genes following the order displayed on the heatmap.
- **kwargs
if plot_emb=True, arguments passed to
scFates.pl.trajectory()
orscFates.pl.dendrogram()
if basis=”dendro”
- adata :
- Returns
- Return type
If show==False a matrix of
Axes