TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Arima Model – Guide to Time Series Forecasting in Python

254 pointsby giladalmost 6 years ago

8 comments

harleykalmost 6 years ago
Aileen Neilsen did a 3 hr session discussing timeseries analysis SciPy 2016. Each chapter is a Python Notebook. The ARIMA model figures prominently in chapter 7 Forecasting. I find her session tremendously helpful when analyzing ts data especially her discussion of seasonality. Youtube walkthrough: <a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=JNfxr4BQrLk" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=JNfxr4BQrLk</a> Github data: <a href="https:&#x2F;&#x2F;github.com&#x2F;AileenNielsen&#x2F;TimeSeriesAnalysisWithPython" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;AileenNielsen&#x2F;TimeSeriesAnalysisWithPytho...</a>
评论 #20255890 未加载
x775almost 6 years ago
Having previously worked with ARIMA and other AR-related models, this is a very comprehensive introduction of ARIMA which anyone interested in learning more about time-series forecasting can benefit from.<p>One point of critique though which is not immediately mentioned in the article: Depending on your data, and especially if your granularity is measured in anything under minutes, you might find the need to continuously calibrate your parameters as to ensure performance over time. I found myself running optimisations in parallel when deploying an ARIMA-inspired model for my use case, for instance. If continuously computing optimisations is not an option, it might be worthwhile implementing outlier detection or simple thresholds to prompt optimisation calls when needed. In either case, ARIMA is definitely a fun rabbit hole to explore if you have not previously worked with time-series forecasting!
rubyfanalmost 6 years ago
Good read, explains a lot.<p>For time series in the past I’ve used Bayesian structural time series with good results. Good article comparing ARIMA to bsts here:<p><a href="https:&#x2F;&#x2F;multithreaded.stitchfix.com&#x2F;blog&#x2F;2016&#x2F;04&#x2F;21&#x2F;forget-arima&#x2F;" rel="nofollow">https:&#x2F;&#x2F;multithreaded.stitchfix.com&#x2F;blog&#x2F;2016&#x2F;04&#x2F;21&#x2F;forget-a...</a>
gregw2almost 6 years ago
Anyone here have a take on when to use Arima vs Holt Winters vs something like R&#x27;s GLM for forecasting time series data which may have seasonal or day-of-week patterns? I&#x27;ve been on projects using all of them and I&#x27;m still not clear on the tradeoffs.
评论 #20258758 未加载
评论 #20259527 未加载
ddmdalmost 6 years ago
One problem I have with statsmodels is that I cannot apply trained models to <i>new</i> data rather than to the train data. In other words I do not want to forecast the train data - I want to forecast completely new time series.<p>For example, here I create and train a model:<p><pre><code> model = ARIMA(df.value, order=(1,1,1)) fitted = model.fit(disp=0) </code></pre> And then I immediately do forecast:<p><pre><code> fc, se, conf = fitted.forecast(...) </code></pre> Yet, it is not what I need. Typically, I store the model and then apply it to many new datasets which are received later.<p>sklearn explicitly supports this pattern (train data set for training and then another data set for prediction).<p>Is it possible in ARIMA and other forecasting algorithms in statsmodels?
评论 #20258857 未加载
Myrmornisalmost 6 years ago
What do people who have experience of getting into the details of time series analysis themselves think of <a href="http:&#x2F;&#x2F;facebook.github.io&#x2F;prophet&#x2F;" rel="nofollow">http:&#x2F;&#x2F;facebook.github.io&#x2F;prophet&#x2F;</a>?
评论 #20255863 未加载
评论 #20259009 未加载
评论 #20267238 未加载
bra-ketalmost 6 years ago
also see hidden markov models: <a href="https:&#x2F;&#x2F;www.quantstart.com&#x2F;articles&#x2F;hidden-markov-models-an-introduction" rel="nofollow">https:&#x2F;&#x2F;www.quantstart.com&#x2F;articles&#x2F;hidden-markov-models-an-...</a>
jlduggeralmost 6 years ago
It&#x27;s kinda amazing that only now have I discovered how useful time series forecasting is for sysadmin&#x2F;devops&#x2F;SRE&#x2F;whatever we call it now.<p>In effect, Icinga (Nagios) represents a local maxima. It&#x27;s very easy to write checks without mathematical or statistical sophistication -- write a check in the language of your choice and return a status enum containing one of three values: OK, WARN, CRIT. A result there&#x27;s a massive collection of checks written by others. Sure the language to configure it sucks, but mostly because it models so many things -- systems to be monitored, how to group systems, the checks to monitor systems with, who to alert, and on what schedule.<p>Instead of doing one thing well, Nagios does everything, kinda poorly. You can&#x27;t easily schedule overrides for an on-call rotation. Event correlation is entirely manual. You have to restart the service to add or remove monitoring -- it&#x27;s not prepared for autoscaling or clustering. It can&#x27;t even scale itself!<p>There is a better way, using a layered approach. Break the task up into multiple steps: Sense, Store, Analzye, Alert, Route. Nagios effectively discards the Store step, and divy up the remaining work between checks and nagios master. Sense+Analyze+Alert are done by the client, and the Nagios master handles alert Routing.<p>(taking it home to the topic) Because Nagios has no Store step, analyze is limited in power. You cannot calculate standard deviations, or even rates of change. ARIMA is impossible, as is ETS. You typically define static thresholds. If there&#x27;s any seasonality, you have to find a static threshold that catches real problems while minimizing false alarms.<p>The downside to the layered model is that there are many different solutions, and every decision point leads to a more fragmented community. How many people out there run statsite+graphite+grafana+opsgenie? A good layered approach needs to fully isolate layers, so that any integration feature or problem is limited to pairings. Usually easy for features, but for bugs, it&#x27;s almost definitionally impossible to prevent a problem in an earlier layer from causing symptoms or or two layers later.<p>tl;dr: I&#x27;ve been mostly learning about ETS (holtwinters) on the job, but would love to learn more about predicting customer traffic.