Message-ID: <1371565976.18433.YahooMailNeo@web142602.mail.bf1.yahoo.com>
Date: 2013-06-18T14:32:56Z
From: arun
Subject: Elementary Help
Hi,
May be this helps:
set.seed(24)
dat1<- data.frame(ID=1:200,value=sample(c(5:200,NA),200,replace=TRUE))
?which(is.na(dat1$value))
#[1]? 56 146 184
sum(which(is.na(dat1$value)))? #Not clear about the 2nd part of the question
#[1] 386
?sum(is.na(dat1$value))
#[1] 3
table(is.na(dat1$value))
#FALSE? TRUE
#? 197???? 3
A.K.
>I am totally new to R, therefore probably this question will be very
easy for most of you. I have a range of values in a column ranging from 5 to 200. >Some of the values are missing, that is, not all student
numbers are there. How do I find which are these missing numbers and
obtain the sum of >these integers?