Answers for "count nan in r"

R
7

how to count the number of NA in r

sum(is.na(df$col))
Posted by: Guest on July-31-2020
1

check for nan in r list

# is.na() can handle lists
# is.nan() can handle only one variable at a time

is.na(NaN)
# TRUE

is.na(NA)
# TRUE
Posted by: Guest on November-20-2020

Browse Popular Code Answers by Language