3

我有大约 100 个 *.xgmml 文件,每个文件都指定了一个不同的网络。如何通过 Cytoscape 为每个输入文件自动生成 PNG 图像文件的过程?

(Cytoscape 命令行选项包括一些用于加载文件的选项,但我没有看到任何用于将网络导出为图像文件的选项。)

4

1 回答 1

3

(在 cytoscape 3+ 中)您可以执行以下操作,将其放入文本文件并使用 cytoscape.sh -S [脚本文件] 运行,或者在打开 cytoscape 后直接进入(工具 -> 执行命令文件):

#Import network
network import file indexColumnTargetInteraction=1 ...
  indexColumnSourceInteraction=2 file="[full path to .xgmml file]"
#Import and set style
vizmap load file file="[full path to .xml style file]"
vizmap apply styles=[style name]
#Set layout
layout attribute-circle
#Set view to fit display
view fit content    
#Save 
view export OutputFile="[full path to output file]" options=PDF

更一般地说,命令行实用程序(工具 -> 命令行对话框)上的帮助命令非常有用。它列出了所有可用的命令,并且可以查询每个命令的语法。

于 2014-12-09T04:35:35.630 回答