Cb.Poisson: Cb calculations for a Poisson (or negative binomial)...

Description Usage Arguments Value Examples

View source: R/Cb.R

Description

Cb calculations for a Poisson (or negative binomial) regression model.

Usage

1
Cb.Poisson(reg_object, tx_var, semi_parametric = FALSE)

Arguments

reg_object

An object of class 'glm' that contains the resuls of the Poisson/NegBin model.

tx_var

A string containing the name of the treatment indicator variable.

semi_parametric

Optional (default=FALSE). If TRUE, the semi-parametric estimator for Cb will be returned.

Value

This function returns an object of class Cb_output, which includes Cb as a member.

Examples

1
2
3
4
data("rct_data")
reg<-glm(formula = n_exac ~ tx + sgrq + prev_hosp + prev_ster + fev1, data = rct_data, family = poisson(link="log"), offset=ln_time)
res.Poisson<-Cb.Poisson(reg,tx_var = "tx", semi_parametric = T)
res.Poisson

resplab/txBenefit documentation built on Jan. 3, 2020, 9:19 p.m.