This is a bug. It has now been fixed in the R-forge source.
I will be updating the package in the next week or so with about a dozen
more indicators, as well as some additional features. At that point I will
push the change to CRAN.
Thanks,
Jeff
Chris-672 wrote:>
> Trying to plot ATR of time series using SMA using quantmod, plots fine
> with maType="EMA".
> However, when I use maType="SMA" I get the following error:
>
> Error in SMA(c(0, 0, 0, 0, 0, ... :
> unused arguments(s) (wilder = FALSE)
> Calls: addATR -> ATR -> do.call -> SMA
> Execution halted
>
> The code I am using is:
>
> addATR(n=20, wilder=FALSE, maType="SMA") # does not work
> addATR(n=20, maType="EMA") # works
fine
>
> Note, the problem still occurs if the wilder argument is modified or
> completely removed.
> This is probably quite simply, but I am very new to [R] - any help
> would be appeciated.
>
> Regards,
>
> Chris.
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
>
--
View this message in context:
http://www.nabble.com/quantmod-ATR-problem-tp20576540p20595551.html
Sent from the R help mailing list archive at Nabble.com.