UPSaltdd {LocalControl} | R Documentation |
Artificial Distribution of LTDs from Random Clusters
Description
For a given number of clusters, UPSaltdd() characterizes the potentially biased distribution of "Local Treatment Differences" (LTDs) in a continuous outcome y-variable between two treatment groups due to Random Clusterings. When the NNobj argument is not NA and specifies an existing UPSnnltd() object, UPSaltdd() also computes a smoothed CDF for the NN/LTD distribution for direct comparison with the Artificial LTD distribution.
Usage
UPSaltdd(
envir,
dframe,
trtm,
yvar,
faclev = 3,
scedas = "homo",
NNobj = NA,
clus = 50,
reps = 10,
seed = 12345
)
Arguments
envir |
name of the working local control classic environment. |
dframe |
Name of data.frame containing a treatment-factor and the outcome y-variable. |
trtm |
Name of treatment factor variable with two levels. |
yvar |
Name of continuous outcome variable. |
faclev |
Maximum number of different numerical values an outcome variable can assume without automatically being converted into a "factor" variable; faclev=1 causes a binary indicator to be treated as a continuous variable determining an average or proportion. |
scedas |
Scedasticity assumption: "homo" or "hete" |
NNobj |
Name of an existing UPSnnltd object or NA. |
clus |
Number of Random Clusters requested per Replication; ignored when NNobj is not NA. |
reps |
Number of overall Replications, each with the same number of requested clusters. |
seed |
Seed for Monte Carlo random number generator. |
Details
Multiple calls to UPSaltdd() for different UPSnnltd objects or different numbers of clusters are typically made after first invoking UPSgraph().
Value
dframeName of data.frame containing X, t & Y variables.
trtmName of treatment factor variable.
yvarName of outcome Y variable.
faclevMaximum number of different numerical values an outcome variable can assume without automatically being converted into a "factor" variable; faclev=1 causes a binary indicator to be treated as a continuous variable determining an average or proportion.
scedasScedasticity assumption: "homo" or "hete"
NNobjName of an existing UPSnnltd object or NA.
clusNumber of Random Clusters requested per Replication.
repsNumber of overall Replications, each with the same number of requested clusters.
patsNumber of patients with no NAs in their yvar outcome and trtm factor.
seedSeed for Monte Carlo random number generator.
altddMatrix of LTDs and relative weights from artificial clusters.
alxminMinimum artificial LTD value.
alxmaxMaximum artificial LTD value.
alymaxMaximum weight among artificial LTDs.
altdcdfVector of artificial LTD x-coordinates for smoothed CDF.
qqVector of equally spaced CDF values from 0.0 to 1.0.
nnltddOptional matrix of relevant NN/LTDs and relative weights.
nnlxminOptional minimum NN/LTD value.
nnlxmaxOptional maximum NN/LTD value.
nnlymaxOptional maximum weight among NN/LTDs.
nnltdcdfOptional vector of NN/LTD x-coordinates for smoothed CDF.
nqOptional vector of equally spaced CDF values from 0.0 to 1.0.
Author(s)
Bob Obenchain <wizbob@att.net>
References
Obenchain RL. (2004) Unsupervised Propensity Scoring: NN and IV Plots. Proceedings of the American Statistical Association (on CD) 8 pages.
Obenchain RL. (2011) USPSinR.pdf USPS R-package vignette, 40 pages.
Rosenbaum PR, Rubin RB. (1983) The Central Role of the Propensity Score in Observational Studies for Causal Effects. Biometrika 70: 41-55.
Rubin DB. (1980) Bias reduction using Mahalanobis metric matching. Biometrics 36: 293-298.
See Also
UPSnnltd
, UPSaccum
and UPSgraph
.