logit_integrand function

Default integrand for the group-level propensity score

Default integrand for the group-level propensity score

Computes the following function: [REMOVE_ME]j=1n(rhj(b))Aj(1rhj(b))1Ajfb(b;θb)prod(rplogis(Xfixef+b)A(1rplogis(Xfixef+b))(1A))dnorm(sd=sqrt(ranef))[REMOVEME2] \prod_{j=1}^{n} (r h_{j}(b))^{A_j} (1 - r h_{j}(b))^{1 - A_j}f_b(b; \theta_b)prod(r * plogis(X * fixef + b)^A *(1 - r * plogis(X * fixef+ b))^(1 - A)) *dnorm(sd = sqrt(ranef)) [REMOVE_ME_2]

where rr is the randomization scheme. XX is the covariate(s) vectors. fixeffixef is the vector of fixed effects. bb is the random (group-level) effect. ranefranef is the random effect variance.

logit_integrand(b, X, A, parameters, allocation = A, randomization = 1)

Arguments

  • b: vector argument of values necessary for integrate.
  • X: n by length(fixed effects) matrix of covariates.
  • A: vector of binary treatments
  • parameters: vector of fixed effect (and random effect if applicable). Random effect should be last element in vector.
  • allocation: The allocation strategy. Defaults to A so that is essentially ignored if allocation is not set to a value within (0, 1).
  • randomization: Randomization probability. Defaults to 1.

Returns

value of the integrand

Description

Computes the following function:

j=1n(rhj(b))Aj(1rhj(b))1Ajfb(b;θb)prod(rplogis(Xfixef+b)A(1rplogis(Xfixef+b))(1A))dnorm(sd=sqrt(ranef)) \prod_{j=1}^{n} (r h_{j}(b))^{A_j} (1 - r h_{j}(b))^{1 - A_j}f_b(b; \theta_b)prod(r * plogis(X * fixef + b)^A *(1 - r * plogis(X * fixef+ b))^(1 - A)) *dnorm(sd = sqrt(ranef))

where rr is the randomization scheme. XX is the covariate(s) vectors. fixeffixef is the vector of fixed effects. bb is the random (group-level) effect. ranefranef is the random effect variance.

  • Maintainer: Bradley Saul
  • License: GPL (>= 2)
  • Last published: 2021-04-21

Useful links