[R-SIG-Finance] getting date of highest value (xts)
Immanuel
mane.desk at googlemail.com
Tue Nov 2 21:26:51 CET 2010
Hello all,
I would like to know when the highest price value
in a given xts time series occurred but I couldn't figure out
how to do this, can anybody help?
thanks
--------------------
# load libraries
library(quantmod)
library(TTR)
getSymbols("^GDAXI")
OHLC.data <- GDAXI["2010-03-01/2010-09-10"]
# I want to know the date where the highest value occurred
max(Hi(GDAXI))
# returns only the highest value, but I would like to know the date...
More information about the R-SIG-Finance
mailing list