Tag: dataframe typeerror

TypeError:write()中不支持的types<type'list'>

我试图通过以下几dicts大量的dicts转储到.xlsx文件中: H=0.5 #Used to name the xlsx file fail_thre=0.2 #Used to name the xlsx file dict_list=[dict1,dict2,dict3] #The list of dictionaries to be dumped myindex=['event 1','event 2','event 3'] #Used to name rows from itertools import izip_longest stats_matrix=[ tuple('dict{}'.format(i+1) for i in range(len(dict_list))) ] + list( izip_longest(*([ v for k,v in sorted(d.items())] for d in dict_list)) ) […]