scanpy change the pdf save path 修改保存地址的路径

scanpy change the pdf save path

修改保存地址的路径

 

figsavePath  =r'aaa\bbb\c'

fig, ax = plt.subplots()
with rc_context({'figure.figsize': (5, 5)}):
    sc.pl.umap(adata, color='choosed', add_outline=True, legend_loc='on data',
               legend_fontsize=12, legend_fontoutline=2, frameon=False,
               title='Leiden: clustering of neurons[{},{}]'.format(begin, end), palette='Set1',show=False)
# 然后对figure进行保存;
plt.savefig(r"{}/leidenCluster.svg".format(figsavePath), format="svg", transparent=True)
posted @   bH1pJ  阅读(80)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· TypeScript + Deepseek 打造卜卦网站:技术与玄学的结合
· Manus的开源复刻OpenManus初探
· AI 智能体引爆开源社区「GitHub 热点速览」
· 三行代码完成国际化适配,妙~啊~
· .NET Core 中如何实现缓存的预热?
点击右上角即可分享
微信分享提示