prop_quant: Stratifying on the Quantiles of the Propensity Score

View source: R/prop_quant.R

prop_quantR Documentation

Stratifying on the Quantiles of the Propensity Score

Description

Stratifying on the quantiles of the propensity score.

Usage

prop_quant(
  data,
  formula,
  exposure.name,
  confound.names,
  probs = 0:4/4,
  quant_var = "pquants"
)

Arguments

data

Dataframe of raw data.

formula

Formula representing the model.

exposure.name

Name of exposure variable.

confound.names

Names of the confound variables.

probs

Vector of probability for the quantiles.

quant_var

Name of the quantile variable. Default is "pquants".

Details

Stratifying on the quantiles is useful to identify the possible interactions between the propensity scores and the exposure.

Value

Dataframe in a useable format for rsample::bootstraps.

Source

Section 10.3. p. 180.

Examples

# An example can be found in the location identified in the
# source section above at the github site
# https://github.com/FrankLef/FundamentalsCausalInference.

FrankLef/fciR documentation built on Nov. 12, 2023, 6:09 a.m.