vd_add_prodid {echoice2} | R Documentation |
Add product id to demand draws
Description
This adds a unique product identifier to demand draw objects.
Usage
vd_add_prodid(de)
Arguments
de |
demand draws |
Value
est
Examples
data(icecream)
#run MCMC sampler (use way more than 10 draws for actual use)
icecream_est <- icecream %>% dplyr::filter(id<10) %>% vd_est_vdm(R=4, keep=1, cores=2)
#Generate demand predictions
icecream_predicted_demand=
icecream %>% dplyr::filter(id<10) %>%
vd_dem_vdm(icecream_est)
#add prodid
icecream_predicted_demand_w_id<-icecream_predicted_demand %>% vd_add_prodid
[Package echoice2 version 0.2.4 Index]