Re: [R] Antwort: RE: Antwort: Fw: Re: Subscripting problem with is.na()

2016-06-27 Thread PIKAL Petr
Hi On top of what Duncan wrote you can check results yourself > str(iris[,"Sepal.Length"]) num [1:150] 5.1 4.9 4.7 4.6 5 5.4 4.6 5 4.4 4.9 ... here you get vector and data.frame class is lost. The result is same as > str(iris$Sepal.Length) num [1:150] 5.1 4.9 4.7 4.6 5 5.4 4.6 5 4.4 4.9 ... How

[R] Antwort: RE: Antwort: Fw: Re: Subscripting problem with is.na()

2016-06-27 Thread G . Maubach
Hi All, Petr, Bert, David, Ivan, Duncan and Rui helped me to develop a function able to replace NA's in variables IF NEEDED: #--- # Module: t_replace_na.R # Author: Georg Maubach # Date : 2016-06

Re: [R] Antwort: RE: Antwort: Fw: Re: Subscripting problem with is.na()

2016-06-27 Thread Duncan Murdoch
On 27/06/2016 7:43 AM, g.maub...@weinwolf.de wrote: Hi Petr, many thanks for your reply and the examples. My subscripting problems drive me nuts. I have understood that dataset[variable] is semantically identical to dataset[, variable] cause dataset[variable] takes all cases because no other s

[R] Antwort: RE: Antwort: Fw: Re: Subscripting problem with is.na()

2016-06-27 Thread G . Maubach
Hi Petr, many thanks for your reply and the examples. My subscripting problems drive me nuts. I have understood that dataset[variable] is semantically identical to dataset[, variable] cause dataset[variable] takes all cases because no other subscripts are given. Where can I lookup the rules w