相关疑难解决方法(0)

在Pandas Dataframe中查找空或NaN条目

我正在尝试搜索Pandas Dataframe以查找缺少条目或NaN条目的位置.

这是我正在使用的数据框:

cl_id            a           c         d         e        A1              A2             A3
    0            1   -0.419279  0.843832 -0.530827    text76        1.537177      -0.271042
    1            2    0.581566  2.257544  0.440485    dafN_6        0.144228       2.362259
    2            3   -1.259333  1.074986  1.834653    system                       1.100353
    3            4   -1.279785  0.272977  0.197011     Fifty       -0.031721       1.434273
    4            5    0.578348  0.595515  0.553483   channel        0.640708       0.649132
    5            6   -1.549588 -0.198588  0.373476     audio       -0.508501               
    6            7    0.172863  1.874987  1.405923    Twenty             NaN            NaN
    7            8   -0.149630 -0.502117  0.315323  file_max             NaN            NaN
Run Code Online (Sandbox Code Playgroud)

注意:空白条目是空字符串 - 这是因为数据框来自的文件中没有字母数字内容.

如果我有这个数据帧,我怎样才能找到包含NaN或空白条目的索引的列表?

indexing list dataframe python-2.7 pandas

28
推荐指数
5
解决办法
6万
查看次数

标签 统计

dataframe ×1

indexing ×1

list ×1

pandas ×1

python-2.7 ×1