python dic problem

dic_cog_annot[h2[1]]={‘orthologous_group':h[3]}
dic_cog_annot[h2[1]][‘protein_annot’]=h[4]
以上是增加个protein_annot键值,

如果是以下,将会被替换,只一个键值!

dic_cog_annot[h2[1]]={‘orthologous_group':h[3]}
dic_cog_annot[h2[1]]={‘protein_annot':h[4]}

 

dic[name]=”NA”

dic[name] = {‘nr_annot':”NA”}
dic[name][‘go_num’]=”NA”
dic[name][‘go_info’] = “NA”
dic[name][‘kegg_hit’] = “NA”
dic[name][‘kegg_annot’]=”NA”
dic[name][‘swiss_annot’]=”NA”
dic[name][‘cog_hit’] =”NA”
dic[name][‘orthologous_group’]=”NA”
dic[name][‘protein_annot’]=”NA”

 

44 comments to python dic problem

Leave a Reply

  

  

  

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>