post_calc: Decomp and contribution calculation function

Description Usage Arguments Value

Description

A function to calucate decomp and contribution

Usage

1
2
post_calc(data, fit, date.start, date.end, var.group, date.group, group,
  is.output = F, is.graph = T)

Arguments

data

a data.table class dataset for modeling.

fit

a fit list from lm_pool output.

date.start

a character of modeling start date in "MM-DD-YYYY".

date.end

a character of modeling start date in "MM-DD-YYYY".

var.group

a data.table with variable group info.

date.group

a data.table with date group inof.

group

a character vector of columns for aggregation

is.output

TRUE output decomp tables.

is.graph

TRUE graph AVP chart.

Value

a list of modeling result. It contains the following components: con: contribution table decomp: decomp table R2 MAPE app: a shiny app


xinzhou1023/shrinkest documentation built on May 4, 2019, 1:07 p.m.