center_ipd | R Documentation |
This function subtracts IPD variables (prognostic variables and/or effect modifiers) by the aggregate data averages. This centering is needed in order to calculate weights. IPD and aggregate data variable names should match.
center_ipd(ipd, agd)
ipd |
IPD variable names should match the aggregate data names without the suffix. This would involve either changing the aggregate data name or the ipd name. For instance, if we binarize SEX variable with MALE as a reference using dummize_ipd, function names the new variable as SEX_MALE. In this case, SEX_MALE should also be available in the aggregate data. |
agd |
pre-processed aggregate data which contain STUDY, ARM, and N. Variable names should be followed by legal suffixes (i.e. MEAN, MEDIAN, SD, or PROP). Note that COUNT suffix is no longer accepted. |
centered ipd using aggregate level data averages
data(adsl_sat)
data(agd)
agd <- process_agd(agd)
ipd_centered <- center_ipd(ipd = adsl_sat, agd = agd)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.