Time_series Flashcards
Describe briefly the time line for a business time series project
What are possible pitfalls when using common metrics to evaluate time-series data?
One can be non stationarity and exploiting autocorrelation . It is very easy to get close to the right time series by simply shifting the values. It is way harder to predict the difference between values more than the actual values.
This are usually called persistence model. Simple autocorrelation plot can highlight this.
What is the ARIMA formula? explain it.
What is BIC?
It is very very similar to AIC
The Bayesian Information Criterion (BIC) is defined as
k log(n)- 2log(L(θ̂)).
Here n is the sample size; the number of observations or number of data points you are working with. k is the number of parameters which your model estimates, and θ is the set of all parameters.
What is exponential smoothign model?
Exponential smoothing uses a similar logic to moving average, but this time, a different decreasing weight is assigned to each observations.
y = ax_t +(1-a)y_t-1
Here, alpha is a smoothing factor that takes values between 0 and 1. It determines how fast the weight decreases for previous observations.
Can we use regression instead of time series analysis for time series data?
Yes and they actually even perform better because we need to take into account a lot of exogenous factors which have impact on sales.
What cross-validation technique would you use on a time series data set.
Instead of using k-fold cross-validation, you should be aware to the fact that a time series is not randomly distributed data — It is inherently ordered by chronological order.
In case of time series data, you should use techniques like forward chaining — Where you will be model on past data then look at forward-facing data.
fold 1: training[1], test[2]
fold 1: training[1 2], test[3]
fold 1: training[1 2 3], test[4]
fold 1: training[1 2 3 4], test[5]
What is differencing and what is it used for ?
- Differencing : This is the commonly used technique to remove non-stationarity. Here we try to model the differences of the terms and not the actual term. For instance,
x(t) – x(t-1) = ARMA (p , q)
This differencing is called as the Integration part in AR(I)MA. Now, we have three parameters
p : AR
d : I
q : MA
Was it shown that modern statistical method like RNN deep NN or LSTM perform better than classical methods?
Actually not. Several papers showed that complex method have not surpassed classical methods yet
What is autocorrelation?
Informally, autocorrelation is the similarity between observations as a function of the time lag between them.
Is this an AM or AR model? What order should you use?
The blue line above shows significantly different values than zero. Clearly, the graph above has a cut off on PACF curve after 2nd lag which means this is mostly an AR(2) process
Do you have to re-train time series forecasting more often than traditional problems?
Yes. Because intrinsticaly the distribution the data are sampled from is changing. Its mean and variance change with time so differently from other problem you have tro retrain almost everytime you make a prediction
how would you increase accuracy of your model if the client needs it?
- Trying new models like NN LSTM regression etc and do bagging of them or stacking
- Ask for businees insight what data or market are important? Are there outliers? what can they be correlated with? Promotions ? big events?
- Explore more data
- have a clear and optimized loss funcion being carefull not to overfit
What is important when meeting a client for a new project?
Understand the data: what data are available what can be available? The maturity of a product to predict is very important
Time scale both on the project lenght and what time of forecast are needed. How far in time we need the prediction to be made?
What aspect should we focus on? sales stocks earnings?
Is it better to underforcast or over forecast?
How much variance can we tolerate? this will be related to the amount of time we have to develop the project?
For production: what is the scale of data? how quickly and how often do we need new forecast?
We can use business experience: what markets or external data are important in your experience? like regulations or stocks prices or weather etc
Think about an example ACF plot`