wght_matrix function

Creates a number of groups by number of allocation schemes matrix of group weights. Allocation schemes are selected by the user.

Creates a number of groups by number of allocation schemes matrix of group weights. Allocation schemes are selected by the user.

Groups should be numbered 1, ..., N

wght_matrix( integrand, allocations, X, A, G, parameters, runSilent = TRUE, integrate_allocation = TRUE, ... )

Arguments

  • integrand: function to pass to the argument 'f' of integrate.
  • allocations: coverage levels in [0, 1]. Can be vector.
  • X: covariate matrix
  • A: vector of treatment assignments
  • G: vector of group assignments
  • parameters: vector of parameters passed to integrand
  • runSilent: if FALSE, errors are printed to console. Defaults to TRUE.
  • integrate_allocation: Indicator of whether the integrand function uses the allocation parameter. Defaults to TRUE.
  • ...: other arguments passed to integrand.

Returns

a length(unique(group)) X length(alphas) matrix of group weights

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

Useful links