RE: [R] fSeries Technical Analysis rsiTA problem

From: Mulholland, Tom <Tom.Mulholland_at_dpi.wa.gov.au>
Date: Wed 20 Apr 2005 - 12:42:33 EST


What does str(tsx) give?

So you are feeding in something the function has no idea about.

Try rsiTA(tsx@Data,14)

Tom

> -----Original Message-----
> From: Neuro LeSuperHéros [mailto:neuro3000@hotmail.com]
> Sent: Wednesday, 20 April 2005 9:42 AM
> To: Mulholland, Tom; r-help@stat.math.ethz.ch
> Subject: RE: [R] fSeries Technical Analysis rsiTA problem
>
>
> Nope, its not that.
>
> I only have one column in there. So
>
> >rsiTA(tsx[,2],14)
> Error in "[.timeSeries"(tsx, , 2) : subscript out of bounds
>
> I get the orginal error with:
>
> >rsiTA(tsx[,1],14)
> Error in "[.timeSeries"(close, 1:(length(close) - 1)) :
> only 0's may be mixed with negative subscripts
>
> Thanks for the answer anyways.
>
>
>
> >From: "Mulholland, Tom" <Tom.Mulholland@dpi.wa.gov.au>
> >To: Neuro LeSuperHéros
> <neuro3000@hotmail.com>,<r-help@stat.math.ethz.ch>
> >Subject: RE: [R] fSeries Technical Analysis rsiTA problem
> Date: Wed, 20 Apr
> >2005 09:23:03 +0800
> >
> >Should you be using rsiTA(tsx[,2],14). If you look at the
> function you will
> >see it is expecting just the values you want in the calculation.
> >
> >If you give it a matrix it treats the whole matrix as being
> price data.
> >
> >Tom
> >
> > > -----Original Message-----
> > > From: r-help-bounces@stat.math.ethz.ch
> > > [mailto:r-help-bounces@stat.math.ethz.ch]On Behalf Of Neuro
> > > LeSuperHéros
> > > Sent: Wednesday, 20 April 2005 8:58 AM
> > > To: r-help@stat.math.ethz.ch
> > > Subject: [R] fSeries Technical Analysis rsiTA problem
> > >
> > >
> > > fSeries Technical Analysis rsiTA problem
> > >
> > > Hello,
> > >
> > > I'm trying to use the rsiTA() function but keep getting
> this error:
> > >
> > > >rsiTA(tsx,14)
> > > Error in "[.timeSeries"(close, 1:(length(close) - 1)) :
> > > only 0's may be mixed with negative subscripts
> > >
> > > Here's is the first three lines of my data:
> > > >tsx[1:3,]
> > > close
> > > 2004-04-18 20:00:00 8702.82
> > > 2004-04-19 20:00:00 8602.98
> > > 2004-04-20 20:00:00 8573.05
> > >
> > > I have 250 days of data.
> > >
> > > Here's the class
> > > >class(tsx)
> > > [1] "timeSeries"
> > > attr(,"package")
> > > [1] "fBasics"
> > >
> > > And here's my version:
> > >
> > > >version
> > > _
> > > platform i386-pc-mingw32
> > > arch i386
> > > os mingw32
> > > system i386, mingw32
> > > status
> > > major 2
> > > minor 1.0
> > > year 2005
> > > month 04
> > > day 18
> > > language R
> > >
> > > I did load the libraries
> > > library(fSeries)
> > > library(fBasics)
> > >
> > > Regards,
> > >
> > > ______________________________________________
> > > R-help@stat.math.ethz.ch mailing list
> > > https://stat.ethz.ch/mailman/listinfo/r-help
> > > PLEASE do read the posting guide!
> > > http://www.R-project.org/posting-guide.html
> > >
>
>
>



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Wed Apr 20 12:46:03 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:31:17 EST