Using quantmod and TTR (for EMA, as well as many, many more technical tools):
library(quantmod) # get some data getSymbols("QQQQ") barChart(QQQQ) addEMA() Lots of examples at: http://www.quantmod.com http://www.quantmod.com ---and--- http://www.quantmod.com/examples/charting/ http://www.quantmod.com/examples/charting/ Do like Dirk suggests and find your way to R-Sig-Finance. Enjoy! Jeff Michael Zak wrote: > > Hi there > > I have some timeseries data which I plot in a OHLC Plot. In the same > plot I'd like to have the EMA of this timeseries. I tried to add the > EMA point to OHLC with lines(), but this doesn't work. Has anyone an > idea how to handle it? > > Regards, Michael Zak > > ______________________________________________ > R-help@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/OHLC-Plot-with-EMA-in-it-tp19669847p19699297.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@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.