optimal.ira1r1
finds constrained optimal sample allocation (COSA) solutions for completely randomized controlled trials
where individuals are randomly assigned to treatment and control groups.
COSA can be found in the following forms,
(i) under budgetary constraints given marginal costs per unit,
(ii) under power contraints given marginal costs per unit,
(iii) under MDES contraints given marginal costs per unit, and
(iv) under sample size contraints for one or more levels along with any of the i,ii, or iii options.
optimal.ira1r1(cn, cost=NULL, n=NULL, power=.80, mdes=.25, alpha=.05, two.tail=TRUE, N0=c(10), ncase=10, gm=10, constrain="cost", optimizer="auglag_cobyla", P=.50, g1=0, R12=0)
NULL
.TRUE
for two-tailed hypothesis testing, FALSE
for one-tailed hypothesis testing."cost"
, "power"
, or "mdes"
."auglag_cobyla"
, "auglag_lbfgs"
, "auglag_mma"
, or "auglag_slsqp"
.An optimization is not necessary because the relationship between contraints and optimal sample is straight forward multiplication or division. Therefore use of this function is not recommended. Nonetheless, this function is provided for consistency and convenience.
Further definition of design parameters can be found in Dong & Maynard (2013).
Dong & Maynard (2013). PowerUp!: A Tool for Calculating Minum Detectable Effect Sizes and Minimum Required Sample Sizes for Experimental and Quasi-Experimental Design Studies,Journal of Research on Educational Effectiveness, 6(1), 24-6.
mdes.ira1r1, power.ira1r1, mrss.ira1r1
## Not run:
#
# optimal.ira1r1(cn=1, cost=560,
# constrain="cost")
#
# ## End(Not run)
Run the code above in your browser using DataLab