我有一个如下列表。
visibility: hidden
我还有一个带列标题的tsv文件 - > mylist=['code1', 'code5', 'code11']
,id
,quantity_details
ingredients
现在,我想仅在id quantity_details ingredients
code1 tim tam 5, sugar 500g recipe of code 1 here.
code2 milk 2L, sugar 250g eggs 5 recipe of code 2 here.
中搜索tsv文件的mylist
列中的代码,并将相应的id
和quantity_details
值作为单个值返回串。即ingredients
的字符串应为= code1
。 <corresponding quantity_details value>
预期产出:
<corresponding ingredients value>
我们可以在python中使用pandas吗?