Re: [R] Subsetting dataframe with missing values

2012-04-27 Thread Petr PIKAL
Hi Dear R-community, I am using R (V 2.14.1) on Windows 7. I have a dataset which consists of 19 variables for 91 individuals or rows. Two of my variables are Age (adult/chick, with no NA values) and Sex (0 for females/1 for females, with quite a few NA values). The sex of many adult

[R] Subsetting dataframe with missing values

2012-04-26 Thread Luciano La Sala
Dear R-community, I am using R (V 2.14.1) on Windows 7. I have a dataset which consists of 19 variables for 91 individuals or rows. Two of my variables are Age (adult/chick, with no NA values) and Sex (0 for females/1 for females, with quite a few NA values). The sex of many adult birds is

Re: [R] Subsetting dataframe with missing values

2012-04-26 Thread Rui Barradas
Hello, Try ?is.na. In the example below I've changed your first row name from NA to NA.0 x - read.table(text= ID Category Sex Beak Head NA.0 NA NA NANA NA NA.1 NA NA NANA NA NA.2 NA NA NANA NA NA.3 NA NA NANA NA