1
$\begingroup$

I am reading this paper: Extracting cycles from Nonstationary Data

I wish to recreate the Monte Carlo simulation in this paper.

I have a query prior to doing this.

On page 8, there is footnote 9, where the author says:

We backfilled $ \epsilon_t $ using 100 observations. This is to ensure that innovation sequence is consistent with the AR(1) generating mechanism.

I did not follow. Can someone please explain to me how to do this ? What exactly is backfilling ?

Here is how I can generate an AR1 sequence similar to the one in the simulation in the paper, of length=216 and autoregressive parameter =.34, using the R programming language:

arima.sim(model =list(ar=.34,order=c(1,0,0)),n=216)

How do I backfill ? Can someone please help me ?

Edit following discussion with mlofton:

Is this how we backfill with a 100 observations??

backfilled.time.series <- c(arima.sim(model =list(ar=.34,order=c(1,0,0)),n=100),
arima.sim(model =list(ar=.34,order=c(1,0,0)),n=216))

or perhaps :

backfilled.time.series <- arima.sim(model =list(ar=.34,order=c(1,0,0)),n=216,n.start=100)

Query : How is backfilling different to generating a longer time series, and ignoring the initial part of the series (which I think is called the burn-in period)?

Edit 2 after reading mlofton's initial response on backfilling:

# Assume that the series to be generated has unconditional mean = 0 and unconditional variance = 1

Here are the IID values as suggested by mlofton
initial.values = rnorm(100,1,0)

backfilled.time.series = arima.sim(model =list(ar=.34,order=c(1,0,0)),n=216,n.start=100,start.innov = initial.values))
$\endgroup$
23
  • 1
    $\begingroup$ It just means to generate iid random variables with zero mean and variance equal to the unconditional variance of the AR1 model. This is one way of dealing with the fact that an AR(1) series needs to be initialized in some way because, in the real world, the earliest data point is $y_1$ rather than $y_{-\infty}$. Note that the unconditional variance of an AR(1) is equal to $\frac{\sigma^2}{(1-\phi^2)}$. $\endgroup$
    – mlofton
    Commented Sep 9 at 0:47
  • $\begingroup$ The link didn't work for me but hopefully the AR(1) doesn't have a non-zero mean because, if it does, then the backfilling should be done using this non-zero mean in additional to the unconditional variance. It also wasn't clear if $\sigma^2$ was given or needed to be estimated. But hopefully why one backfills is more clear now. You don't want the initial values in the series to have a distorting effect on the series. This can happen because, in an AR(1), the value of an observation at time $t$ is related to the value at time $(t-1)$ and we don't have a value at time $(t-1)$ when $(t=1)$. $\endgroup$
    – mlofton
    Commented Sep 9 at 0:54
  • $\begingroup$ Dear mlofton, my apologies for the link not working. Does this link work for you ? Please see the first result on this link scholar.google.com/… $\endgroup$ Commented Sep 9 at 6:51
  • $\begingroup$ Yes. Thanks. It worked. I will print it out but it will take time for me to read it because I don't have much these days. Did you understand my latest comment ? I'm never sure on how clear my explanations are ? But backfilling, as far as I know, is just that: Create say 100 normal random variables with the same mean as the process and the variance equal to the unconditional mean of the process. Attach these to the beginning of the series and they can serve as $y_{(-99)}, y_{(-98)}, \ldots, y_{0}$ in the series. You are basically just making your series longer. $\endgroup$
    – mlofton
    Commented Sep 10 at 3:48
  • $\begingroup$ Keep in mind that the long term mean of the process depends on whether the AR(1) has an non-zero mean. Also, note that the the long term mean of say $y_t = \phi y_{t-1} + \mu$ is $\frac{\mu}{1-\phi}$ and not $\mu$. $\endgroup$
    – mlofton
    Commented Sep 10 at 3:51

1 Answer 1

1
$\begingroup$

I read the pages the footnote but my answer doesn't change. What I think they are doing is just attaching 100 normal rv's with those characteristics ( the unconditional variance and mean zero ) to the beginning of the series.

Notice that I was mistaken about $\sigma^2$ not being specified. $\epsilon_t$ is specified as N(0,1) so $\sigma^2 = 1$ but I don't see how they can just claim that unless it's irrelevant to the construction of $\sum_{t} g_{t}$ ? The only other thing I can think of doing is emailing the author and asking them why they use $\sigma^2 = 1$ for the variance of $\epsilon_t$ in the AR(1) process ? The generation of the backfilled $\epsilon$ would still be done as I explained but it seems like N(0,1) was just pulled out of thin air ?

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.