hey does anyone know how to loop through the MedRV function in the RTAQ package?
I have
##find days in data
ddx.f = endpoints(full, on="days");
days.full = format(index(full)[ddx.f], "%Y-%m-%d");
for (day in days.full) {
x = full[day]
}
to extract each day but don’t know what to add to loop through the MedRV function per each day.
Any ideas? And also does anyone know is there a significance test in R to test for jumps?
Thanks in advance.
The idea is the same as your last question
Split the data into days, and apply a function to each day. Below
split(dxts, "days")will create a list where each element is 1 day of data.lapplywill apply a function to each day.Then
rbindthe results into a single xts objectEdit/Alternate syntax