compute_risk: Compute risk value

Description Usage Arguments Value

View source: R/compute_risk.R

Description

Calculates the cross-validated risk for the optimal bandwidth selection in kernel smoothing approach.

Usage

1
compute_risk(h, matched_Y, matched_w, w_vals)

Arguments

h

A scalar representing the bandwidth value.

matched_Y

A vector of outcome variable in the matched set.

matched_w

A vector of continuous exposure variable in the matched set.

w_vals

A vector of values that you want to calculate the values of the ERF at.

Value

returns a cross-validated risk value for the input bandwidth


CausalGPS documentation built on Feb. 7, 2022, 5:12 p.m.