prop_wald Calculates a single proportion and related standard error according to Wald and provides degrees of freedom to be used in function with.miceafter.

prop_wald(x, formula, data)

Arguments

x

name of variable to calculate proportion.

formula

A formula object to specify the model as normally used by glm.

data

An objects of class milist, created by df2milist, list2milist or mids2milist.

Value

The proportion, standard error and complete data degrees of freedom (dfcom) as n-1.

Author

Martijn Heymans, 2021

Examples

imp_dat <- df2milist(lbpmilr, impvar="Impnr")
ra <- with(imp_dat, expr=prop_wald(Chronic ~ 1))