Country, custom events and mixed features
match ← All flat growth benchmarks96 days with US country holidays, custom events, conditional weekly seasonality and a promotion regressor. Holiday effects are multiplicative.
Input
benchmark/inputs/v5/country-mixed-96.json: 96 history rows and 4 forecast rows.
Output
Largest difference: 3.0e-5 (0.00062% of the input's range).
Every forecast row from both libraries.
| Date | Effect Prophet | Python Prophet | Difference |
|---|---|---|---|
| 2024-12-25 | 21.7611 | 21.7611 | 3.0e-5 |
| 2025-01-01 | 23.0406 | 23.0407 | 1.1e-5 |
| 2025-01-02 | 20.6095 | 20.6095 | 9.9e-6 |
| 2025-01-05 | 20.7451 | 20.7450 | 3.0e-5 |
Timing
Median of all measured repetitions.
| Step | Effect Prophet | Python Prophet | Effect Prophet is |
|---|---|---|---|
| Convert input rows | 46 µs | 499 µs | 11× faster |
| Fit | 17.8 ms | 54.9 ms | 3.1× faster |
| Predict | 222 µs | 6.23 ms | 28× faster |
| Fit and predict | 17.1 ms | 61.4 ms | 3.6× faster |
| Convert, fit and predict | 18.3 ms | 61.6 ms | 3.4× faster |
| First forecast in a new process | 196 ms | 1.65 s | 8.4× faster |
| Save model to JSON | 108 µs | 704 µs | 6.5× faster |
| Load model from JSON | 810 µs | 4.30 ms | 5.3× faster |
| Load and predict in a new process | 167 ms | 1.60 s | 9.6× faster |
Settings
The case declaration both libraries ran.
json
{
"kind": "map",
"comparison": {
"kind": "equivalent-objective",
"evidenceId": "country-calendar-public-v1"
},
"configuration": {
"growth": "flat",
"countryHolidays": {
"country": "US",
"coverage": "reject-known-gaps",
"priorScale": 10
},
"scaling": "absmax",
"seasonalityMode": "additive",
"holidaysMode": "multiplicative",
"changepoints": {
"mode": "auto",
"count": 25,
"range": 0.8
},
"changepointPriorScale": 0.05,
"seasonalities": [
{
"name": "weekly-active",
"periodDays": 7,
"fourierOrder": 1,
"priorScale": 10,
"conditionName": "active"
}
],
"events": [
{
"name": "launch",
"date": "2024-01-01",
"lowerWindowDays": 0,
"upperWindowDays": 0,
"priorScale": 10
},
{
"name": "launch",
"date": "2024-01-05",
"lowerWindowDays": 0,
"upperWindowDays": 0,
"priorScale": 10
},
{
"name": "launch",
"date": "2025-01-01",
"lowerWindowDays": 0,
"upperWindowDays": 0,
"priorScale": 10
},
{
"name": "launch",
"date": "2025-01-05",
"lowerWindowDays": 0,
"upperWindowDays": 0,
"priorScale": 10
}
],
"regressors": [
{
"name": "promotion",
"priorScale": 10,
"standardization": "never"
}
]
},
"pythonOptimizer": {
"algorithm": "Auto",
"maxIterations": 10000,
"newtonFallback": true,
"sigFigs": 12
}
}