Executes all the other package functions in order to have a list with the results table.

run_synthetic_forecast(
  df,
  col_unit_name,
  unit_of_interest,
  col_time,
  periods_to_forecast,
  serie_of_interest
)

Arguments

df

Main DataFrame.

col_unit_name

String with column name of the column with the units names.

unit_of_interest

Value of the col_unit_name that is of interest.

col_time

String with the column name of the time column.

periods_to_forecast

(Integer) Number of periods to forecast.

serie_of_interest

Column name os the serie to be projected.

Value

List with results table.

Examples

# \donttest{ synthetic_forecast <- run_synthetic_forecast( df = df_example, col_unit_name = 'unit', col_time='time_period', periods_to_forecast=12, unit_of_interest = '30', serie_of_interest = 'x1' )
#> [1] "Forecasting Unit: 30 . Serie: x1" #> #> X1, X0, Z1, Z0 all come directly from dataprep object. #> #> #> **************** #> searching for synthetic control unit #> #> #> **************** #> **************** #> **************** #> #> MSPE (LOSS V): 0.005105562 #> #> solution.v: #> 0.03795838 0.02953412 0.03356642 0.01533716 0.1226315 0.1285906 0.05816525 0.02318678 0.01465216 0.01080646 0.06187415 0.0289542 0.01702719 0.08006876 0.009607601 0.01627082 0.1278952 0.02615566 0.01342692 0.04431671 0.04468165 0.01097563 0.04431671 #> #> solution.w: #> 1.1452e-05 0.0002666085 0.0001873182 0.0002686277 0.0001636778 0.0003347625 0.0004905744 0.0005939929 0.0005203545 0.5502766 4.8739e-06 0.0007708196 0.0003844661 0.001002508 0.000803214 0.000999687 0.1285913 0.3143298 #>
# }