R: Hypothesis testing for arima time series object

503 views Asked by At

I'm trying to perform a hypothesis test for an arima forecast, and I haven't been able to find resources for it. Below is a reproducible example of my data. I'm using a zoo time series because my frequency is weekdays only.

The hypothesis test I'd like to perform is:

H1: The forecasted value is greater than a specified value which I'd provide,

H0: There is no difference in values.

library(timeDate)
library(forecast)
library(zoo)
library(magrittr)

set.seed(12345)

dates=timeSequence('2017-09-01','2017-09-08')
dates=dates[isWeekday(dates)]%>%as.character()%>%as.POSIXct()
# Need to drop the timeDate class

values=rnorm(n=6,mean=12500,sd=500)

cumValues=cumsum(values)

zooObj=zoo(cumValues,dates)

arimaModel=auto.arima(zooObj)

So for this data, the predicted next value is:

 > forecast(arimaModel,h=1)
       Point Forecast    Lo 80    Hi 80    Lo 95    Hi 95
1504929600       83612.53 78117.67 89107.39 75208.87 92016.19

I'd like to hypothesis test the probability that the next value is greater than 83,000.

0

There are 0 answers