Loading...
Loading...
Compare original and translation side by side
IRON LAW: Prophet Is an Additive Regression Model, NOT Classical Time Series
y(t) = g(t) + s(t) + h(t) + ε(t)
- g(t): piecewise linear or logistic trend with automatic changepoints
- s(t): Fourier series for yearly/weekly/daily seasonality
- h(t): user-specified holiday effects
Prophet does NOT model autocorrelation in residuals. If residuals are
autocorrelated, the uncertainty intervals will be too narrow.IRON LAW: Prophet Is an Additive Regression Model, NOT Classical Time Series
y(t) = g(t) + s(t) + h(t) + ε(t)
- g(t): piecewise linear or logistic trend with automatic changepoints
- s(t): Fourier series for yearly/weekly/daily seasonality
- h(t): user-specified holiday effects
Prophet does NOT model autocorrelation in residuals. If residuals are
autocorrelated, the uncertainty intervals will be too narrow.m = Prophet(); m.fit(df)m.predict(future)m = Prophet(); m.fit(df)m.predict(future)cross_validation()cross_validation(){
"forecasts": [{"ds": "2025-04-15", "yhat": 1200, "yhat_lower": 1050, "yhat_upper": 1350}],
"components": {"trend": "upward_3pct", "yearly_seasonality": "peak_in_december", "weekly_seasonality": "low_on_weekends"},
"metadata": {"mape": 0.08, "training_days": 730, "forecast_days": 90}
}{
"forecasts": [{"ds": "2025-04-15", "yhat": 1200, "yhat_lower": 1050, "yhat_upper": 1350}],
"components": {"trend": "upward_3pct", "yearly_seasonality": "peak_in_december", "weekly_seasonality": "low_on_weekends"},
"metadata": {"mape": 0.08, "training_days": 730, "forecast_days": 90}
}| Input | Expected | Why |
|---|---|---|
| Many missing days | Prophet handles natively | Unlike ARIMA, no imputation needed |
| Sudden trend change | Changepoint detected automatically | Prophet's key feature vs ARIMA |
| Multiplicative seasonality | Set seasonality_mode='multiplicative' | When seasonal amplitude grows with trend |
| 输入 | 预期结果 | 原因 |
|---|---|---|
| 存在大量缺失日期 | Prophet原生支持处理 | 与ARIMA不同,无需进行插补 |
| 趋势突然变化 | 自动检测到变点 | 这是Prophet相对ARIMA的核心特性 |
| 乘法季节性 | 设置seasonality_mode='multiplicative' | 当季节性幅度随趋势增长时适用 |
changepoint_prior_scalechangepoint_prior_scalereferences/prophet-tuning.mdreferences/prophet-cv.mdreferences/prophet-tuning.mdreferences/prophet-cv.md