On Sep 25, 2011, at 2:18 PM, David Cross wrote:
Here is my problem: I have saved ten variables as an R binary file
(using save). Now, when I load the file (using load), I have access
to each of the variables individually (as objects), but not to all
ten variables as a set. The reason this
Here is my problem: I have saved ten variables as an R binary file (using
save). Now, when I load the file (using load), I have access to each of the
variables individually (as objects), but not to all ten variables as a set.
The reason this is important is that I want to clean the data of all
> To: r-help@r-project.org
> Subject: Re: [R] Handling missing data
>
>
> I have one column
> x
> 97
> 94
> 91
> 90
> NA
> NA
> NA
> NA
> I tried
> i tried this
> book$r<-ifelse(book$x!=NA,book$x+20,10)
> expected result
> 107
> 104
What you want is:
book$r<-ifelse(is.na(book$r), 10,book$x+20)
On Fri, Oct 9, 2009 at 5:46 AM, premmad wrote:
>
> I have one column
> x
> 97
> 94
> 91
> 90
> NA
> NA
> NA
> NA
> I tried
> book$r<-ifelse(book$x!=NA,book$x+20,10)
> I expect to get the result as follows
> 107
> 104
> 91
> 90
> 10
>
I have one column
x
97
94
91
90
NA
NA
NA
NA
I tried
book$r<-ifelse(book$x!=NA,book$x+20,10)
I expect to get the result as follows
107
104
91
90
10
10
10
10
But what i was getting is empty column of variable r.How to solve this
--
View this message in context:
http://www.nabble.com/Handlin
Reproducible code.???
premmad wrote:
>
> I have to remove missing data both in character and numeric datatype.I
> tried using NA condition but it is not working ,please help me to solve
> this.
>
-
Blay S
KATH
Kumasi, Ghana.
--
View this message in context:
http://www.nabble.com/Han
ow" ; ; "premmad"
Sent: Monday, September 21, 2009 7:20 PM
Subject: Re: [R] Handling missing data
Vassilis Golfinopoulos wrote:
Consider this sample dataset (displayed [1:3, 1:3]):
T1053B T1102A T1129A
AKT1 -0.02412174 0.1986057 NA
AURKA -0.37109748
gt; Help us to help you, show us the code that you tried, what you expected, and
>> what you saw.
>>
>> Does "using NA condition" mean:
>>
>>> x == NA
>> Which does not work
>>
>> Or
>>
>>> is.na(x)
>> Which should.
;> is.na(x)
>
> Which should.
>
> -Original Message-
> From: "premmad"
> To: "r-help@r-project.org"
> Sent: 9/21/09 12:38 AM
> Subject: [R] Handling missing data
>
>
> I have to remove missing data both in character and numeric data
Sent: 9/21/09 12:38 AM
Subject: [R] Handling missing data
I have to remove missing data both in character and numeric datatype.I tried
using NA condition but it is not working ,please help me to solve this.
--
View this message in context:
http://www.nabble.com/Handling-missing-data-tp2553019
I have to remove missing data both in character and numeric datatype.I tried
using NA condition but it is not working ,please help me to solve this.
--
View this message in context:
http://www.nabble.com/Handling-missing-data-tp25530192p25530192.html
Sent from the R help mailing list archive at
11 matches
Mail list logo