crude.risk {blm}R Documentation

Risk-exposure scatter plot

Description

Calculates the weighted average crude risk against the average exposure level for a continuous exposure. Each point corresponds to overlapping subgroups of 20 percent of the sample ordered from lowest to highest exposure and a sliding window of 1

Usage

crude.risk(formula, data, weights = NULL, na.action = na.omit) 

Arguments

formula

formula specifying the binary outcome and the continuous covariate of interest, e.g. y~x

data

dataframe containing the variables specified in formula

weights

vector of sample weights

na.action

function used for handling missing variables in the variables of formula and weights

Details

The crude.risk function is intended to explore the possible functional relationship between risk and exposure in a non-parametric way.

Author(s)

S. Kovalchik s.a.kovalchik@gmail.com

See Also

risk.exposure.plot

Examples


data(aarp)

risk <- crude.risk(bladder70~redmeat,
		  weights = aarp$w,
		  data = aarp)

risk.exposure.plot(risk,
		   xlab = "Avg. Red Meat Consumption")


[Package blm version 2022.0.0.1 Index]