标签: python pandas dask
是否存在相当于pandas empty功能的dask?我想检查dask数据帧是否为空,但df.empty返回AttributeError: 'DataFrame' object has no attribute 'empty'
empty
df.empty
AttributeError: 'DataFrame' object has no attribute 'empty'
答案 0 :(得分:4)
Dask目前不支持此功能,但您可以动态计算长度:
len(df) == 0
len(df.index) == 0 # Likely to be faster