Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

setup_dataframe

Prepare dataframe for fitting or predicting.


Description

Adds a time index and scales y. Creates auxillary columns 't', 't_ix', 'y_scaled', and 'cap_scaled'. These columns are used during both fitting and predicting.

Usage

setup_dataframe(m, df, initialize_scales = FALSE)

Arguments

m

Prophet object.

df

Data frame with columns ds, y, and cap if logistic growth. Any specified additional regressors must also be present.

initialize_scales

Boolean set scaling factors in m from df.

Value

list with items 'df' and 'm'.


prophet

Automatic Forecasting Procedure

v1.0
MIT + file LICENSE
Authors
Sean Taylor [cre, aut], Ben Letham [aut]
Initial release
2021-03-08

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.