`import sys, os, subprocess
def velvet_assembly(fastqs,output):
#cmd is a command line within the programme#
cmd=['velveth', output, '59', '-fastq.gz', '-shortPaired',fastqs[0],fastqs[1]]
my_file=subprocess.Popen(cmd)
my_file.wait()
velvet_assembly(fastqs,output)`
这就是我使用cmd将命令行包含在我不久前用python2.7编写的程序中的方式。显然,您必须更改您的数据类型。你知道吗
在这个链接中你可以得到一些其他的例子。 [https://www.cyberciti.biz/faq/python-run-external-command-and-get-output/][1]
希望这是有用的。你知道吗
相关问题 更多 >
编程相关推荐