Questions tagged [moving-window]

A window is a fixed-length subset of consecutive observations of a time series. The window is moved along the time series at a constant rate. Also known as "rolling window".

Filter by
Sorted by
Tagged with
3
votes
1answer
83 views

Is moving average(sliding window) a smoothing technique or forecasting technique?

The rolling average method is mostly used to produce a smoothed series by removing noise. For ex- 3 window moving average, in general practice, the output for the fourth period is the 3 window moving ...
1
vote
1answer
43 views

How do we forecast using 3 point moving average?

X<- c(3,6,8,10,6,5) If I want to forecast using 3point moving average I use ma(X,3) from forecast package So this is going to give a series of smoothed average. If I want to forecast further 2 ...
0
votes
0answers
45 views

Multivariate Garch DCC-ROLL in R (RMGARCH)

Little Disclaimer I originally posted this on Stack Overflow, but I'm not sure which is the correct place, because this question demands a knowledge of Econometrics. So, I'll replicate here and if I'...
0
votes
0answers
34 views

Efficient online (rolling window) estimation of a GARCH model

I have a time series $x_t$ of length $n$. I would like to model it using rolling window approach with window length (width) $w$: window $1$: $x_1,\dots,x_w$, window $2$: $x_2,\dots,x_{w+1}$, $\dots$, ...
1
vote
1answer
67 views

Out-of-sample Rolling window forecast with ARIMA(0,0,0) with non-zero mean

I am doing a rolling window out-of-sample forecast and have fitted an ARIMA(0,0,1) model to a first difference time series. People argue that sometimes simpler models are better than more complicated ...
1
vote
0answers
38 views

Counting occurrences using n-grams

I was asked to do the following exercise: Consider the sequence IROIRDXMIRDOMORIORMTDMMDMWBIRQGDM Count the number of occurences of IRDM using: n-grams ...
1
vote
0answers
30 views

Computation of multiple linear OLS regression with rolling window and/or update

How can I efficiently calculate an OLS fit for N multiple variables for a rolling window? I've worked out how to do it for 1 and 2 variable linear fits, I'd like to extend to the general case of N ...
2
votes
1answer
65 views

What is the relationship between average of a rolling intercept and the intercept from a regression over the entire period?

If i calculate rolling (e.g. 3 periods back) intercepts for a time series using OLS, is the average of these rolling intercepts then in some way related to the intercept from an OLS of the entire ...
0
votes
0answers
17 views

Predictions in time series

I am working on project about the kitchen sink method and the lasso. My objective is to make in the sample predictions by, of course, taking part of the database as historical data and the other part ...
2
votes
1answer
18 views

Ranking with multiple weights/ features

We have entities where every entity has start ($s_i$) and end ($e_i$) times and count $c_i$. An entity is important if its interval ($e_i - s_i$) is large and if its $c_i$ is large. Here's what I ...
0
votes
0answers
61 views

Deciding Rolling mean and standard-deviation Window of a Time-Series Distribution

I have a Daily time-series data of 6 years. And I need to do Weekly forecasting on this Daily-basis data. Before forecasting, I want to find rolling mean & STD to determine the stationarity of ...
0
votes
1answer
95 views

ARIMA + Rolling Window

I'm currently working on building an ARIMA+GARCH model using R. My dataset consists of the logarithmic returns of the Dow Jones index for a period of 11 years 2005-2016, however, it's worth noting ...
0
votes
0answers
24 views

How to estimate policy impact using interrupted time series, when outcome variable is a moving average?

Suppose you want to evaluate the impact of a recently implemented policy using interrupted time series because you have no comparison group and the policy was implemented all at once on the ...
0
votes
1answer
33 views

How does the sliding window work?

I am not sure how the "Sliding window" method work. Let's assume I have a dataset of number of logins by hour. a) A window of 24hours to predict the next 24h? b) A window of 24h to predict the next ...
1
vote
0answers
69 views

What is the difference between a discrete and continuous rolling window?

What I have read so far suggests that a discrete rolling window is say a yearly window, calculating somethig every year, which is from 01-01/31-12 and a continuous rolling window is a window that ...
0
votes
0answers
212 views

LSTM - When to use sliding window in time series classification?

Say I have a tensor of data with shape (30, 16000, 38) - where each tuple element corresponds to ...
2
votes
1answer
118 views

How to compute the change of Ridge regression solution when one row of data changes?

I understand that $\boldsymbol{\beta} = (X^TX + \lambda I)^{-1}X^T\mathbf{ Y}$ is the closed form solution of Ridge regression. So sometimes, when I run a rolling window, meaning everytime I run the ...
0
votes
0answers
83 views

Is it fair to consider rolling regression a form of bootstrapping?

The context is time series analysis. A few similarities between rolling regression and boostrapping jump out at me, in that both re-use observations to form new subsamples for estimation. However, ...
0
votes
0answers
70 views

Constructing signal vector of EWMA

I have daily stock returns related to sectors. At the end of each month I want to construct a vector of signals using the past data with different methods over different moving windows like EWMA over ...
1
vote
0answers
258 views

How to make predictions on sliding window?

I need help understanding how to construct sliding windows as well as how to perform final prediction. Any help is appreciated! I have a dataset from sensing data with multiple features aggregated ...
0
votes
1answer
1k views

What is rolling mean and standard deviation in terms of stationarity?

I would like to know what a rolling mean and rolling S.D means in terms of achieving stationairty concerning a time series? I ran an ADF test and it told me my time series was stationary however, by ...
1
vote
0answers
42 views

Classify time series with unequal lenghts [closed]

I have a set of time series sensor measurements (acceleration and gyroscope readings) for driving events (harsh acceleration, harsh brake …) with the type, start and end of each event. I need to ...
0
votes
0answers
18 views

Is it possible to make LSTM model with 4dimension shape?

Hellow, wizards. I have time series data including sevaral days. I try to predict a grade of tomorrow, which is range from 0 to 100. And I assume that this grade depends on 3 time-series independent ...
1
vote
0answers
32 views

Average time series forecast errors from cross-validation with rolling origin

I'm calculating the MAPE and RMSE over a rolling origin cross-validation with fixed forecast interval for several models. For example, for a daily series with 3 years, I'm training my model with 2 ...
2
votes
2answers
172 views

Rolling Window Forecasting with ARIMAX while supplying actual values

I am comparing different exogenous variables in how good they support the forecast of the monthly seasonal adjusted unemployment rate. All my data is monthly (2006-01-01 until 2018-09-01) and ...
2
votes
1answer
1k views

How to decide moving window size for time series prediction?

I have a model to predict +1 day ahead of this time series. Looking at the chart you can notice some seasonality every 5 days. I suspect using a moving window as training set could help me making a ...
0
votes
1answer
86 views

DNN methodology and feature concatenation

I'm using someone else's job and I have a question that I cannot solve. This work uses a DNN to match an electrical resistance to a bend angle. This is not very important, just for the context. So,...
2
votes
1answer
163 views

Impact of window size on estimated volatility using SMA or EWMA

When calculating volatility (either using an SMA or EWMA approach), what impact does the window size have on the volatility estimate?
2
votes
1answer
132 views

Markov Switching GARCH - Expanding or Rolling window forecasting?

When modelling volatility do people tend to use expanding or sliding windows to predict the performance of MS GARCH models?
1
vote
1answer
92 views

Rolling sum of 2 sample KS test results

In order to compare two lists of samples from 'before-treatment' and 'after-treatment', I am doing a two sample KS test using the ks_2samp function from Python's scipy.stats package which gives me the ...
0
votes
1answer
220 views

Moving window time series

I am working on some computations for large datasets of market data and I was wondering is there is a simple way to apply the following logic without using heavy looping. I will simplify the problem: ...
2
votes
1answer
37 views

Using a recoded window 10 days back in a GAM-model, is that a double whammy or is it OK to do?

I'm formulating a prediction in a logistic reression type in a GAM model. ...
2
votes
1answer
552 views

Supervised learning: setting labels on sliding windows of sensor data

Suppose that I have a set of accelerometer data collected with one sensor and one label for each measured data point. These labels describe different states of my system e.g., $state_A, state_B, ...
1
vote
1answer
791 views

Detrending using moving average

In Terrence C. Mills book Im currently reading The Foundation of Modern Time Series Analysis on while discussing Person's detrending methods, he mentions the following result. ... Concider the ...
1
vote
0answers
37 views

How to perform windowframing for timeseries prediction

I am working on a market prediction project based on the timeseries data. Essentially i am trying to windowframe the data and predict whether the price goes up or down in an hour, 30 minutes and 15 ...
0
votes
0answers
314 views

Rolling window AR(2)-GARCH(1,1) VaR intuition query

I have an AR(2)-GARCH(1,1) model and I need to use a 1-day rolling window 1 -step ahead forecasts to calculate the 5% conditional VaR. I know how to calculate the VaR for 1-step ahead only - I ...
1
vote
0answers
53 views

Critique my method for predicting easter product sales from daily data

I hope this question benefits the site as well as myself. Thanks ahead for your time. So I work for a company that sells (among a lot of things) personalized items specifically for Easter - stuffed ...
2
votes
0answers
46 views

Picking the right prediction model

I am having a hard time trying to make/pick a prediction model in R. The data: I have information on 40 different players, with all their recorded performances(training loads) over the last season. ...
2
votes
1answer
249 views

Time Series: relating duration of one time series to events

I have a stats question, and not enough experience to even begin to know how to find the answer. It's a time series question relating two time series: A = anomolous conditions (-,0,+) --- continuous ...
0
votes
1answer
1k views

Difference between 'Time domain features' and 'frequency domain features'?

I have a time series data of accelerometer in X,Y,Z axis. Data is not sampled at a constant sampling rate(but is close to 100 Hz). In the paper I am referring, it mentions that for feature selection I ...
1
vote
0answers
78 views

How to use rasters in R to create a logit model?

I created land-use rasters for the city of Montreal for 2012, 2014, and 2016; all of which I converted from vectors to rasters in QGIS. I want to create a logit model to predict land-use changes. I ...
1
vote
0answers
453 views

How to handle/preprocess time dependent features in a neural network

I want to use a neural network to model a biological continuous variable. This variable depends on a bunch of events that happened in the preceding hours, sometimes up to 24 hours, including the ...
1
vote
0answers
205 views

Use sliding window to find variance for seasonal time series in R

I would like to estimate the variance of a time series. Say, if the time series has a period of 24, and I want to estimate the variance using $$ \sigma_t^2 = \frac{1}{2k+1} \sum^k_{-k} (y_{t+24k} - \...
7
votes
3answers
3k views

Tuning an exponential moving average to a moving window mean?

The alpha parameter of an exponential moving average defines the smoothing that the average applies to a time series. In a similar way, the window size of a moving window mean also defines the ...
4
votes
2answers
4k views

Selecting ARIMA Order using Rolling Forecast

I'm wondering if a rolling forecast technique like the ones mentioned in Rob Hyndman's blogs, and the example below, could be used to select the order for an ARIMA model? In the examples I've looked ...
1
vote
1answer
2k views

Rolling forecasts: training versus forecast accuracy evaluation

Questions: Are rolling forecast examples (like the ones below) only useful for evaluating a model's accuracy, or can a rolling forecast be used to train a model? Are models trained using a rolling ...
0
votes
1answer
560 views

Question about rolling forecast horizon

I'm trying to understand how the rolling forecast example below from Rob Hyndman's blog works. In the final line of the for loop, is ...
1
vote
1answer
1k views

Are rolling forecasts more accurate that full-sample forecasts?

I compared the auto.arima forecast checkts below to the rolling forecast fc and noticed ...
1
vote
0answers
783 views

Sliding window with labelled time series of sensor data

I'm using a sliding window to obtain features (like mean, varianve etc) of a labelled time series of sensor readings. The goal is to train a binary classifier (like linear regression or SVM) to detect ...
3
votes
0answers
188 views

Good book / resource for learning about moving window PCA?

I would like recommendations on textbooks (or online resources) covering MWPCA theoretically and with application examples (preferably in R, but also in Python, Mathematica, Matlab). A brief intro: ...