SMAC-Group / TTS

"A Tour of Time Series Analysis with R" (TTS) is a text that is aimed to provide better explanations for students investigating dependency within observations.
6 stars 5 forks source link

Add a discussion on robust methods in Chapter 2 #1

Closed stephaneguerrier closed 8 years ago

stephaneguerrier commented 8 years ago

Rob could you please add a very simple intro on the issue? I added a small simulation to illustrate the impact of outliers on the estimation of the ACF. Maybe we could present Yanyuan's estimator (without defining it) and show that it works. It could be good to add an example with real data, I think the example with high-frequency financial data would be perfect. Merci bcp!

robertomolinari commented 8 years ago

Yanyuan’s estimator is not implemented in R. I used the “robber” package. Where can I find the high-frequency financial data?

stephaneguerrier commented 8 years ago

Hi Rob, that's perfect. Code for the high-freq data is in section 1.2:

# Load packages
library(timeDate)

# Load "high-frequency" Starbucks returns for Jul 01 2011
data(sbux.xts, package = "highfrequency")

# Plot returns
par(mfrow = c(1,2))
plot(sbux.xts[1:89], main = " ", ylab = "Returns")
plot(sbux.xts, main = " ", ylab = "Returns")
stephaneguerrier commented 8 years ago

@robertomolinari this is done, right?

coatless commented 8 years ago

@stephaneguerrier missing the code for the simulation.

The robust comments were included in: 8d4476cc047199b4b3da6d835303bcc8e358c153

along with spelling tweaks.

stephaneguerrier commented 8 years ago

Ok, thanks. Please close this issue when u get the code.

robertomolinari commented 8 years ago

Done !