我有以下的解释:筛选器列表的字典在Python
dict = {'Sex':['Male','Male','Female','Female','Male'],
'Height': [100,200,150,80,90],
'Weight': [20,60,40,30,30]}
我希望能够过滤使用条件字典上的一个键。例如,如果我想继续只限男性:
new_dict = {'Sex':['Male','Male','Male'],
'Height': [100,200,90],
'Weight': [20,60,30]}
将其转换成数据库。 –
谢谢但我的配置不理想。 – user2475110
你想成为多么灵活?可以举另一个例子为“height> 100”吗? –