ppR: ppR: prior period variable creation

Description Details

Description

Make prior period summary variables from longitudinal data.

Details

ppR contains methods to handle the creation and implementation of by-group weighted mean and count variables for preceding records of the same group in data which spans time. The main function for training these variables is train_ppgrid, which will create a just-in-time summary for each time-group combination. This can be scored on new data with the method merge_ppgrid, which returns the just-in-time weighted mean and count for a new dataframe as a list.

The time variable is currently expected to be strictly a numeric, with other parameters supplied on the same scale. Support of datetime objects is planned.


DexGroves/ppR documentation built on May 6, 2019, 2:13 p.m.