Data4DM / BayesSD

Data for Decision, Affordable Analytics for All
8 stars 0 forks source link

Mismatching time step of driving data and generator model #18

Closed hyunjimoon closed 5 months ago

hyunjimoon commented 1 year ago

Inventory management model is weekly-based, but customer order rate data is reported monthly (from 1992-01-01 to 2016-05-01 with its value 10^5 magnitude).

tomfid commented 1 year ago

This is pretty typical. Normally I would probably pretend that a month is 4 weeks, ignoring variable month length. Then use a moving window to aggregate the weekly data to monthly, and use IF THEN ELSE or SAMPLE IF TRUE to sample only the end-of-month data points.

You then have a potential alignment problem, because the inventory data at month 3/week 12 is inventory(t=12) while the flow data are lagged. IOW what you'd normally call the production for month 3 is probably production(t=12,13,14,15). However, if the generator and estimator flavors of the model are comparing the same reporting stock, the time alignment might not matter. It's more a matter of caution for interpreting real data.