rweSimuSingleArm: Simulate outcomes for a single arm study

Description Usage Arguments

View source: R/rwe_simu.R

Description

Simulate outcomes for a single arm study

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
rweSimuSingleArm(
  nPat,
  muCov,
  sdCov,
  corCov,
  regCoeff,
  mix.phi = 1,
  cov.breaks = NULL,
  fmla = NULL,
  type = c("continuous", "binary"),
  ysig = NULL,
  sig2Ratio = 1,
  b0 = NULL,
  bin.mu = 0.5,
  ...
)

Arguments

nPat

number of patients

muCov

mean vector of covariates

sdCov

standard deviation vector of covariates

corCov

correlation of covariates

regCoeff

regression coefficients

mix.phi

weight in mixture model

cov.breaks

breaks to cut covaraites into categories. If numeric, the same cuts will be applied to all covariates. If list, each covariates will be categorized based on its own breaks. If NULL, keep continuous.

type

distributions of the random error

ysig

standard error of the random error

b0

intercept in regession model

bin.mu

mean of the binary outcomes used to compute b0


olssol/rwetools documentation built on April 18, 2021, 11:42 a.m.