Hi all! Would this be an appropriate implementati...
# random
d
Hi all! Would this be an appropriate implementation of the Simple Combination of Univariate Model (SCUM) if I have monthly data (all positive) and I want to generate 2 years worth of predictions?
Copy code
# Monthly dataset:
df = df[['unique_id', 'ds', 'y']]

seasonality = 12 

models = [
    AutoETS(model = 'ZZZ', season_length = seasonality),
    DynamicOptimizedTheta(season_length = seasonality),
    AutoCES(season_length = seasonality),
    AutoARIMA(season_length = seasonality)
]

# Instantiate StatsForecast class
sf = StatsForecast( 
    df = d_new,
    models = models,
    freq = 'MS', 
    n_jobs = -1,
    fallback_model = SeasonalNaive(season_length = seasonality)
)

sf.fit()

d_sf = sf.predict(h=24)
model_cols = [c for c in d_sf.columns if c != 'ds']

d_sf['yhat'] = d_sf[model_cols].clip(0).median(axis=1, numeric_only=True)
m
Hello! I haven't run the code on my end, but looks like you're taking the median of different statistical models, which seems reasonable to me!
t
@DANIEL KIM I think it's pretty much 95% there. Missing some extra logic they use at least in the paper for some sample size and seasonality based edge cases: https://eprints.lancs.ac.uk/id/eprint/131943/1/IJF_2019_SCUM_post_print_.pdf
I would also be curious about trying out MFLES to replace one of the methods! Maybe the autoets for automfles!
d
Sounds good, thank you for your feedback! I'll check out automfles as well
d
Haven't heard of SCUM method before, thanks for the links!
❤️ 1
d
It’s really nice to see how it performs!