Quantcast
Channel: Pandas dataframe, get the row and index for a column meeting certain conditions - Stack Overflow
Viewing all articles
Browse latest Browse all 3

Answer by quasi-human for Pandas dataframe, get the row and index for a column meeting certain conditions

$
0
0

You can also use a np.where method as follows:

import numpy as npempty_status_idx = np.where(df.Status.isnull())[0].tolist()

[0, 2]

Viewing all articles
Browse latest Browse all 3

Trending Articles