sc.pl.tsne()

2025-04-21  本文已影响0人  LET149

sc.pl.tsne()

https://scanpy.readthedocs.io/en/stable/api/generated/scanpy.pl.tsne.html#scanpy.pl.tsne

Cell embeding and clustering

sc.pl.tsne(adata, use_raw=, layer=, color=, size=, palette=, legend_fontsize=, legend_loc=, show=)

    1. use_raw=: use the .raw data for plot or not; default=None, the .raw will be used for plotting
    1. layer=: key in .layer used for plot; de fault=None, .X will be used for plot
    1. color=: the key of .obs or .var used for color the plot
    1. size=: size of the scatter; 7 is good
    1. palette=: colors used for plot; 'Set1', 'Set2' and 'Set3' can be choosed
    1. legend_fontsize=: 指定图例中字体大小;选择 7 比较合适
    1. legend_loc=: cluster 标记显示的位置;on data 表示标记在图中;legend_loc=None 表示不绘制 legend
    1. show=: if plot the figure; default=True, plot the figure rather than return for plot; for return plot, it should be False

sc.pl.tsne(integration_of_Chem_FCA_and_AD_FCA, color="data", legend_fontsize='7')

Gene expression level

sc.pl.tsne(adata, use_raw=, layer=, color=, size=, color_map=, legend_fontsize=, legend_loc=, show=, title=)

    1. use_raw=: use the .raw data for plot or not; default=None, the .raw will be used for plotting
    1. layer=: key in .layer used for plot; de fault=None, .X will be used for plot
    1. color=: the key of .obs or .var used for color the plot
    1. size=: size of the scatter; 7 is good
    1. color_map=: 当用基因表达进行配色时,改变配色方案;viridis 为经典配色;viridis_r 为反向经典配色,比较常用;其他配色包括 magmamagma_r
    1. legend_fontsize=: 指定图例中字体大小;选择 7 比较合适
    1. legend_loc=: cluster 标记显示的位置;on data 表示标记在图中;legend_loc=None 表示不绘制 legend
    1. show=: if plot the figure; default=True, plot the figure rather than return for plot; for return plot, it should be False
    1. title=: title of this plot

sc.pl.tsne(scanpy_object, layer='normalized', color='', color_map='viridis_r', size=6, title='Krt14')

上一篇 下一篇

猜你喜欢

热点阅读