                              Package ‘RProbSup’
                                            October 12, 2022
Type Package
Title Calculates Probability of Superiority
Version 3.0
Author John Ruscio
Maintainer John Ruscio <ruscio@tcnj.edu>
Description The A() function calculates the A statistic, a nonparametric
      measure of effect size for two independent groups that’s also known as
      the probability of superiority (Ruscio, 2008), along with its standard
      error and a confidence interval constructed using bootstrap methods
      (Ruscio & Mullen, 2012). Optional arguments can be specified to
      calculate variants of the A statistic developed for other research
      designs (e.g., related samples, more than two independent groups or
      related samples; Ruscio & Gera, 2013).
      <DOI:10.1037/1082-989X.13.1.19>.
      <DOI:10.1080/00273171.2012.658329>.
      <DOI:10.1080/00273171.2012.738184>.
License MIT + file LICENSE
Encoding UTF-8
LazyData true
NeedsCompilation no
Repository CRAN
Date/Publication 2020-10-19 04:40:06 UTC
R topics documented:
          A . . .   . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
          A1 . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
          A2 . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
          AAD1 .    . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
          AAD2 .    . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
          AAPD1     . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
          AAPD2     . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
                                                      1
2                                                                                                          A
         CalcA1 . . . .    . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . .  9
         CalcA2 . . . .    . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 10
         CalcAAD1 . .      . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 11
         CalcAAD2 . .      . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 12
         CalcAAPD1 . .     . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 13
         CalcAAPD2 . .     . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 14
         CalcIK1 . . . .   . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 15
         CalcIK2 . . . .   . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 16
         CalcOrd1 . . .    . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 17
         CalcOrd2 . . .    . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 18
         IK1 . . . . . .   . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 19
         IK2 . . . . . .   . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 20
         Ord1 . . . . . .  . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 21
         Ord2 . . . . . .  . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 22
         RemoveMissing     . . . . . . . . . . . . .  . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Index                                                                                                     24
  A                            A
Description
    Calculates probability of superiority (A), its standard error, and a confidence interval.
Usage
    A(data, design = 1, statistic = 1, weights = FALSE,
    w = 0, w1 = 0, w2 = 0, increase = FALSE, ref = 1, r = 0,
    n.bootstrap = 1999, conf.level = .95, ci.method = 1, seed = 1)
Arguments
    data               For a between subjects design, a matrix of cases (rows) by scores (column 1)
                       and group codes (column 2). For a within subjects design, a matrix of scores
                       with each sample in its own column (matrix).
    design             Design of experiment (scalar, default = 1 (for between subjects design), user can
                       also call 2 (for within subjects design)).
    statistic          Statistic to be calculated (scalar, default = 1 (A), user can also call 2 (A.AAD),
                       3 (A.AAPD), 4 (A.IK), or 5 (A.Ord)).
    weights            Whether to assign weights to cases (default = FALSE); if set to TRUE, data
                       contains case weights in final column.
    w                  Weights for cases (vector; default = 0).
    w1                 Weights for cases in group 1 (vector; default = 0).
    w2                 Weights for cases in group 2 (vector; default = 0).
A1                                                                                                       3
    increase             Set to TRUE if scores are predicted to increase with group codes (default =
                         FALSE).
    ref                  Reference group (to compare to all others) (scalar, default = 1).
    r                    Vector of proportions (vector, default = 0, represents equal proportions).
    n.bootstrap          Number of bootstrap samples (scalar, default = 1999).
    conf.level           Confidence level (default = .95).
    ci.method            Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                         can also call 2 (for percentile)).
    seed                 Random number seed (scalar, default = 1).
Value
    Returns list object with the following elements: A : A statistic (scalar). SE : Standard error of A
    (scalar). ci.lower : Lower bound of confidence interval (scalar). ci.upper : Upper bound of confi-
    dence interval (scalar). conf.level : Confidence level (scalar). n.bootstrap : Number of bootstrap
    samples (scalar). boot.method : Bootstrap method ("BCA" or "percentile"). n : Sample size (after
    missing data removed; scalar). n.missing : Number of cases of missing data, removed listewise
    (scalar).
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    data <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
    A(data, 1, 2)
  A1                            A1
Description
    Calculates the standard error and constructs a confidence interval for the A statistic using bootstrap
    methods.
Usage
    A1(y1, y2, weights = FALSE, w1 = 0, w2 = 0, n.bootstrap = 1999,
    conf.level = .95, ci.method = 1, seed = 1)
4                                                                                                     A2
Arguments
    y1                  Scores for group 1 (vector).
    y2                  Scores for group 2 (vector).
    weights             Whether to weight cases (default = FALSE).
    w1                  Weights for cases in group 1 (optional) (vector, default is 0).
    w2                  Weights for cases in group 2 (optional) (vector, default is 0).
    n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
    conf.level          Confidence level (scalar, default = .95).
    ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                        can also call 2 (for percentile).
    seed                Random number seed (scalar, default = 1).
Value
    A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
    the confidence interval.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    #Example used in Ruscio and Mullen (2012)
    y1 <- c(6, 7, 8, 7, 9, 6, 5, 4, 7, 8, 7, 6, 9, 5, 4)
    y2 <- c(4, 3, 5, 3, 6, 2, 2, 1, 6, 7, 4, 3, 2, 4, 3)
    A1(y1, y2)
  A2                           A2
Description
    Calculates the standard error and constructs a confidence interval for the A statistic for two corre-
    lated samples using bootstrap methods.
Usage
    A2(y1, y2, weights = FALSE, w = 0, n.bootstrap = 1999,
    conf.level = .95, ci.method = 1, seed = 1)
AAD1                                                                                                    5
Arguments
    y1                  Scores for group 1 (vector).
    y2                  Scores for group 2 (vector).
    weights             Whether to weight cases (default = FALSE).
    w                   Weights for cases in group 1 (optional) (vector, default is 0).
    n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
    conf.level          Confidence level (scalar, default = .95).
    ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                        can also call 2 (for percentile).
    seed                Random number seed (scalar, default = 1).
Value
    A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
    the confidence interval.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    y1 <- c(6, 7, 8, 7, 9, 6, 5, 4, 7, 8, 7, 6, 9, 5, 4)
    y2 <- c(7, 5, 6, 7, 6, 4, 3, 5, 4, 5, 4, 5, 7, 4, 5)
    A2(y1, y2)
  AAD1                         AAD1
Description
    Calculates the confidence interval for the A statistic for the average absolute deviation for two or
    more groups.
Usage
    AAD1(y, r = 0, weights = FALSE, n.bootstrap = 1999, conf.level = .95,
    ci.method = 1, seed = 1)
6                                                                                                 AAD2
Arguments
    y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
    r                   Vector of proportions (default = 0, represents equal proportions) (vector).
    weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
    n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
    conf.level          Confidence level (scalar, default = .95).
    ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                        can also call 2 (for percentile).
    seed                Random number seed (scalar, default = 1).
Value
    A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
    the confidence interval.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
    AAD1(y)
  AAD2                         AAD2
Description
    Calculates the confidence interval for the A statistic for the average absolute deviation for two or
    more correlated samples.
Usage
    AAD2(y, r = 0, weights = FALSE, n.bootstrap = 1999,
    conf.level = .95, ci.method = 1, seed = 1)
AAPD1                                                                                                   7
Arguments
    y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
    r                   Vector of proportions (default = 0, represents equal proportions) (vector).
    weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
    n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
    conf.level          Confidence level (scalar, default = .95).
    ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                        can also call 2 (for percentile).
    seed                Random number seed (scalar, default = 1).
Value
    A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
    the confidence interval.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(x1, x2, x3)
    AAD2(y)
  AAPD1                        AAPD1
Description
    Calculates the confidence interval for the A statistic for the average absolute paired deviation for
    two or more groups.
Usage
    AAPD1(y, weights = FALSE, n.bootstrap = 1999,
    conf.level = .95, ci.method = 1, seed = 1)
8                                                                                                AAPD2
Arguments
    y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
    weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
    n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
    conf.level          Confidence level (scalar, default = .95).
    ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                        can also call 2 (for percentile).
    seed                Random number seed (scalar, default = 1).
Value
    A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
    the confidence interval.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
    AAPD1(y)
  AAPD2                        AAPD2
Description
    Calculates the confidence interval for the A statistic for the average absolute paired deviation for
    two or more correlated samples.
Usage
    AAPD2(y, weights = FALSE, n.bootstrap = 1999,
    conf.level = .95, ci.method = 1, seed = 1)
CalcA1                                                                                                  9
Arguments
    y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
    weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
    n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
    conf.level          Confidence level (scalar, default = .95).
    ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                        can also call 2 (for percentile).
    seed                Random number seed (scalar, default = 1).
Value
    A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
    the confidence interval.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(x1, x2, x3)
    AAPD2(y)
  CalcA1                        CalcA1
Description
    Calculates the A statistic for 2 groups.
Usage
    CalcA1(y1, y2, weights = FALSE, w1 = 0, w2 = 0)
10                                                                                      CalcA2
Arguments
     y1                 Scores for group 1 (vector).
     y2                 Scores for group 2 (vector).
     weights            Whether to weight cases (default = FALSE).
     w1                 Weights for cases in group 1 (optional) (vector, default is 0).
     w2                 Weights for cases in group 2 (optional) (vector, default is 0).
Value
     a                  The A statistic.
Author(s)
     John Ruscio
References
     Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
     #Example used in Ruscio and Mullen (2012)
     y1 <- c(6, 7, 8, 7, 9, 6, 5, 4, 7, 8, 7, 6, 9, 5, 4)
     y2 <- c(4, 3, 5, 3, 6, 2, 2, 1, 6, 7, 4, 3, 2, 4, 3)
     CalcA1(y1, y2)
   CalcA2                        CalcA2
Description
     Calculates the A statistic for 2 correlated samples.
Usage
     CalcA2(y1, y2, weights = FALSE, w = 0)
Arguments
     y1                 Scores for variable 1 (vector).
     y2                 Scores for variable 2 (vector).
     weights            Whether to weight cases (default = FALSE).
     w                  Weights (optional) (vector, default is 0).
Value
     a                  The A statistic.
CalcAAD1                                                                                            11
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    y1 <- c(6, 7, 8, 7, 9, 6, 5, 4, 7, 8, 7, 6, 9, 5, 4)
    y2 <- c(7, 5, 6, 7, 6, 4, 3, 5, 4, 5, 4, 5, 7, 4, 5)
    CalcA2(y1, y2)
  CalcAAD1                     CalcAAD1
Description
    Calculates the A statistic for the average absolute deviation for two or more groups. Note: This
    function is not meant to be called by the user, but it is called by AAD1.
Usage
    CalcAAD1(y, r = 0, weights = FALSE)
Arguments
    y                  Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                       trix).
    r                  Vector of proportions (default = 0, represents equal proportions) (vector).
    weights            Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                       weights (default = FALSE).
Value
    a                  The A statistic.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
12                                                                                           CalcAAD2
Examples
     x1 <- rnorm(25)
     x2 <- x1 - rnorm(25, mean = 1)
     x3 <- x2 - rnorm(25, mean = 1)
     y <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
     CalcAAD1(y)
   CalcAAD2                     CalcAAD2
Description
     Calculates the A statistic for the average absolute deviation for two or more correlated samples.
     Note: This function is not meant to be called by the user, but it is called by AAD2.
Usage
     CalcAAD2(y, r = 0, weights = FALSE)
Arguments
     y                  Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
     r                  Vector of proportions (default = 0, represents equal proportions) (vector).
     weights            Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
Value
     a                  The A statistic.
Author(s)
     John Ruscio
References
     Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
     x1 <- rnorm(25)
     x2 <- x1 - rnorm(25, mean = 1)
     x3 <- x2 - rnorm(25, mean = 1)
     y <- cbind(x1, x2, x3)
     CalcAAD2(y)
CalcAAPD1                                                                                            13
  CalcAAPD1                     CalcAAPD1
Description
    Calculates the A statistic for the average absolute paired deviation for two or more groups. Note:
    This function is not meant to be called by the user, but it is called by AAPD1.
Usage
    CalcAAPD1(y, weights = FALSE)
Arguments
    y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
    weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
Value
    a                   The A statistic.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
    AAPD1(y)
14                                                                                           CalcAAPD2
   CalcAAPD2                     CalcAAPD2
Description
     Calculates the A statistic for the average absolute paired deviation for two or more correlated sam-
     ples. Note: This function is not meant to be called by the user, but it is called by AAPD2.
Usage
     CalcAAPD2(y, weights = FALSE)
Arguments
     y                  Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
     weights            Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
Value
     a                  The A statistic.
Author(s)
     John Ruscio
References
     Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
     x1 <- rnorm(25)
     x2 <- x1 - rnorm(25, mean = 1)
     x3 <- x2 - rnorm(25, mean = 1)
     y <- cbind(x1, x2, x3)
     AAPD2(y)
CalcIK1                                                                                              15
  CalcIK1                       CalcIK1
Description
    Calculates the A statistic while singling out one group for two or more groups. Note: This function
    is not meant to be called by the user, but it is called by IK1.
Usage
    CalcIK1(y, ref = 1, weights = FALSE)
Arguments
    y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
    ref                 Reference group (to compare to all others) (scalar, default = 1).
    weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
Value
    a                   The A statistic.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
    CalcIK1(y)
16                                                                                             CalcIK2
   CalcIK2                      CalcIK2
Description
     Calculates the A statistic while singling out one group for two or more correlated samples. Note:
     This function is not meant to be called by the user, but it is called by IK2.
Usage
     CalcIK2(y, ref = 1, weights = FALSE)
Arguments
     y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                         trix).
     ref                 Reference group (to compare to all others) (scalar, default = 1).
     weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                         weights (default = FALSE).
Value
     a                   The A statistic.
Author(s)
     John Ruscio
References
     Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
     x1 <- rnorm(25)
     x2 <- x1 - rnorm(25, mean = 1)
     x3 <- x2 - rnorm(25, mean = 1)
     y <- cbind(x1, x2, x3)
     CalcIK2(y)
CalcOrd1                                                                                            17
  CalcOrd1                     CalcOrd1
Description
    Calculates the ordinal comparison of the A statistic for two or more groups. Note: This function is
    not meant to be called by the user, but it is called by AOrd1.
Usage
    CalcOrd1(y, weights = FALSE, increase = FALSE)
Arguments
    y                  Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                       trix).
    weights            Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                       weights (default = FALSE).
    increase           Set to TRUE if scores are predicted to increase with group codes (default =
                       FALSE).
Value
    a                  The A statistic.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
    CalcOrd1(y)
18                                                                                             CalcOrd2
   CalcOrd2                     CalcOrd2
Description
     Calculates the ordinal comparison of the A statistic for two or more correlated samples. Note: This
     function is not meant to be called by the user, but it is called by AOrd2.
Usage
     CalcOrd2(y, weights = FALSE, increase = FALSE)
Arguments
     y                  Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
     weights            Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
     increase           Set to TRUE if scores are predicted to increase with group codes (default =
                        FALSE).
Value
     a                  The A statistic.
Author(s)
     John Ruscio
References
     Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
     x1 <- rnorm(25)
     x2 <- x1 - rnorm(25, mean = 1)
     x3 <- x2 - rnorm(25, mean = 1)
     y <- cbind(x1, x2, x3)
     CalcOrd2(y)
IK1                                                                                                   19
  IK1                          IK1
Description
    Calculates the confidence interval for the A statistic while singling out one group for two or more
    groups.
Usage
    IK1(y, ref = 1, weights = FALSE, n.bootstrap = 1999,
    conf.level = .95, ci.method = 1, seed = 1)
Arguments
    y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
    ref                 Reference group (to compare to all others) (scalar, default = 1).
    weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
    n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
    conf.level          Confidence level (scalar, default = .95).
    ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                        can also call 2 (for percentile).
    seed                Random number seed (scalar, default = 1).
Value
    A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
    the confidence interval.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
    IK1(y)
20                                                                                                    IK2
   IK2                          IK2
Description
     Calculates the confidence interval for the A statistic while singling out one group for two or more
     correlated samples.
Usage
     IK2(y, ref = 1, weights = FALSE, n.bootstrap = 1999,
     conf.level = .95, ci.method = 1, seed = 1)
Arguments
     y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                         trix).
     ref                 Reference group (to compare to all others) (scalar, default = 1).
     weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                         weights (default = FALSE).
     n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
     conf.level          Confidence level (scalar, default = .95).
     ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                         can also call 2 (for percentile).
     seed                Random number seed (scalar, default = 1).
Value
     A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
     the confidence interval.
Author(s)
     John Ruscio
References
     Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
     x1 <- rnorm(25)
     x2 <- x1 - rnorm(25, mean = 1)
     x3 <- x2 - rnorm(25, mean = 1)
     y <- cbind(x1, x2, x3)
     IK2(y)
Ord1                                                                                                  21
  Ord1                         Ord1
Description
    Calculates the confidence interval for the ordinal comparison of the A statistic for two or more
    groups.
Usage
    Ord1(y, weights = FALSE, increase = FALSE, n.bootstrap = 1999,
    conf.level = .95, ci.method = 1, seed = 1)
Arguments
    y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                        trix).
    weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                        weights (default = FALSE).
    increase            Set to TRUE if scores are predicted to increase with group codes (default =
                        FALSE).
    n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
    conf.level          Confidence level (scalar, default = .95).
    ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                        can also call 2 (for percentile).
    seed                Random number seed (scalar, default = 1).
Value
    A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
    the confidence interval.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- rnorm(25)
    x2 <- x1 - rnorm(25, mean = 1)
    x3 <- x2 - rnorm(25, mean = 1)
    y <- cbind(c(x1, x2, x3), c(rep(1, 25), rep(2, 25), rep(3, 25)))
    Ord1(y)
22                                                                                                  Ord2
   Ord2                         Ord2
Description
     Calculates the confidence interval for the ordinal comparison of the A statistic for two or more
     correlated samples.
Usage
     Ord2(y, weights = FALSE, increase = FALSE, n.bootstrap = 1999,
     conf.level = .95, ci.method = 1, seed = 1)
Arguments
     y                   Matrix of cases (rows) by scores (column 1) and group codes (column 2) (ma-
                         trix).
     weights             Weight of each case. Set to TRUE to weight cases; if so, column 3 contains case
                         weights (default = FALSE).
     increase            Set to TRUE if scores are predicted to increase with group codes (default =
                         FALSE).
     n.bootstrap         Number of bootstrap samples (scalar, default = 1999).
     conf.level          Confidence level (scalar, default = .95).
     ci.method           Method used to construct confidence interval (scalar, default = 1 (for BCA), user
                         can also call 2 (for percentile).
     seed                Random number seed (scalar, default = 1).
Value
     A vector containing the A statistic, its estimated standard error, and the upper and lower bounds of
     the confidence interval.
Author(s)
     John Ruscio
References
     Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
     x1 <- rnorm(25)
     x2 <- x1 - rnorm(25, mean = 1)
     x3 <- x2 - rnorm(25, mean = 1)
     y <- cbind(x1, x2, x3)
     Ord2(y)
RemoveMissing                                                                                   23
  RemoveMissing               RemoveMissing
Description
    Checks for missing data and performs listwise deletion if any is detected.
Usage
    RemoveMissing(data)
Arguments
    data               For a between subjects design, a matrix of cases (rows) by scores (column 1)
                       and group codes (column 2). For a within subjects design, a matrix of scores
                       with each sample in its own column (matrix).
Value
    Data matrix with any missing data removed using listwise deletion of cases.
Author(s)
    John Ruscio
References
    Ruscio (2008) & Ruscio and Mullen (2012) & Ruscio and Gera (2013)
Examples
    x1 <- c(rnorm(25), NA)
    x2 <- x1 - rnorm(26, mean = 1)
    x3 <- x2 - rnorm(26, mean = 1)
    data <- cbind(c(x1, x2, x3), c(rep(1, 26), rep(2, 26), rep(3, 26)))
    A(data, 1, 2)
Index
A, 2
A1, 3
A2, 4
AAD1, 5
AAD2, 6
AAPD1, 7
AAPD2, 8
CalcA1, 9
CalcA2, 10
CalcAAD1, 11
CalcAAD2, 12
CalcAAPD1, 13
CalcAAPD2, 14
CalcIK1, 15
CalcIK2, 16
CalcOrd1, 17
CalcOrd2, 18
IK1, 19
IK2, 20
Ord1, 21
Ord2, 22
RemoveMissing, 23
                  24
