我是python的新手。我试图解析一个文件来提取某些列并写入输出文件。我能够解析和提取所需的列,但在将它们写入输出文件时遇到了困难。在
以下是原始测试文件:
EGW05759 Pld5 I79_005987 GO_function: GO:0003824 - catalytic activity [Evidence IEA]; GO_process: GO:0008152 - metabolic process [Evidence IEA]
EGW05760 Exo1 I79_005988 GO_function: GO:0003677 - DNA binding [Evidence IEA]; GO_function: GO:0003824 - catalytic activity [Evidence IEA]; GO_function: GO:0004518 - nuclease activity [Evidence IEA]; GO_process: GO:0006281 - DNA repair [Evidence IEA]
这是我的python代码
^{pr2}$基本上,我希望输出看起来像这样(虽然我知道我的代码不完整,无法实现这一点)
Pld5 GO:0003824:GO:0008152
Exo1 GO:0003677:GO:0003824:GO:0004518:GO:0006281
谢谢
厄本德拉
使用
csv
模块:相关问题 更多 >
编程相关推荐