Skip to contents

Computes the score-style z statistic for testing the null risk difference p_T - p_C = delta in two independent binomial samples, using the Miettinen-Nurminen constrained nuisance estimates.

Usage

mn_z_statistic_cpp(x_t, n_t, x_c, n_c, delta, p_t_obs, p_c_obs)

Arguments

x_t

Number of events in treatment.

n_t

Number of subjects in treatment.

x_c

Number of events in control.

n_c

Number of subjects in control.

delta

Null risk difference.

p_t_obs

Observed treatment-arm risk.

p_c_obs

Observed control-arm risk.

Value

The asymptotic z statistic.