> Perfect!
> Exactly what I was looking for.
> Thanks
> Lorenzo
> On Fri, May 27, 2016 at 01:50:03PM +0200, Christian Brandstätter wrote:
>> Hi Lorenzo,
>>
>> Try:
>>
>> tt[is.nan(tt)] <- NA
>> tt <- na.omit(tt)
>>
or simply na.omit(tt)
as it omits both NA and NaN (and *does* keep the 'ts'
Hm
> -Original Message-
> From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Jim Lemon
> Sent: Friday, May 27, 2016 12:46 PM
> To: Lorenzo Isella
> Cc: r-help@r-project.org
> Subject: Re: [R] Getting Rid of NaN in ts Object
>
> Hi Lorenzo,
> M
Perfect!
Exactly what I was looking for.
Thanks
Lorenzo
On Fri, May 27, 2016 at 01:50:03PM +0200, Christian Brandstätter wrote:
Hi Lorenzo,
Try:
tt[is.nan(tt)] <- NA
tt <- na.omit(tt)
Best,
Christian
Am 27.05.2016 um 13:38 schrieb Lorenzo Isella:
On Fri, May 27, 2016 at 08:46:20PM +1000,
Hi Lorenzo,
Try:
tt[is.nan(tt)] <- NA
tt <- na.omit(tt)
Best,
Christian
Am 27.05.2016 um 13:38 schrieb Lorenzo Isella:
On Fri, May 27, 2016 at 08:46:20PM +1000, Jim Lemon wrote:
Hi Lorenzo,
Maybe:
tt<-tt[!is.nan(tt)]
Jim
Not really.
tt<-structure(c(NaN, NaN, NaN, NaN, NaN, NaN, NaN,
On Fri, May 27, 2016 at 08:46:20PM +1000, Jim Lemon wrote:
Hi Lorenzo,
Maybe:
tt<-tt[!is.nan(tt)]
Jim
Not really.
tt<-structure(c(NaN, NaN, NaN, NaN, NaN, NaN, NaN, NaN, NaN, NaN,
+ NaN, NaN, NaN, NaN, NaN, NaN, NaN, NaN, 1133.09, 1155.77, 1179.12,
+ 1182.85, 1133.43, 1103.36, 1081.19, 10
Hi Lorenzo,
Maybe:
tt<-tt[!is.nan(tt)]
Jim
On Fri, May 27, 2016 at 8:14 PM, Lorenzo Isella
wrote:
> Dear All,
> I am sure the answer is a one liner, but I am banging my head against
> the wall and googling here and there has not helped much.
> Consider the following time series
>
> tt<-structu
Dear All,
I am sure the answer is a one liner, but I am banging my head against
the wall and googling here and there has not helped much.
Consider the following time series
tt<-structure(c(NaN, NaN, NaN, NaN, NaN, NaN, NaN, NaN, NaN, NaN,
NaN, NaN, NaN, NaN, NaN, NaN, NaN, NaN, 1133.09, 1155.77,
7 matches
Mail list logo