[R] Null values In R.
Dieter Menne
dieter.menne at menne-biomed.de
Wed Dec 3 07:50:02 CET 2008
paul murima wrote:
>
>
> My problem is largely when i attempt to use correlation for my data...
> xcc <- cor(a);
>
> The error i get is as follows
>
> Error in cor(a) : missing observations in cov/cor
>
As Daniel suggested, it is always best to use the function's parameter to
handle NULLs. In other cases, it could help to do
a <- na.omit(a)
but be careful: this may throw away to many rows when you have more than 2
columns.
Dieter
--
View this message in context: http://www.nabble.com/Null-values-In-R.-tp20806622p20807696.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list