The pem function returns the percentage of phase B data exceeding the phase A median. Additionally, a chi square test against a 50/50 distribution is computed. Different measures of central tendency can be addressed for alternative analyses.
A single-case data frame or a list of single-case data frames. See makeSCDF to learn about this format.
decreasing
If you expect data to be lower in the B phase, set decreasing = TRUE. Default is decreasing = FALSE.
binom.test
Computes a binomial test for a 50/50 distribution. Default is binom.test = TRUE.
chi.test
Computes a Chi-square test. The default setting chi.test = FALSE skips the Chi-square test.
FUN
Data points are compared with the phase A median. Use this argument to implement alternative measures of central tendency. Default is FUN = median
…
Additional arguments for the FUN parameter (e.g. FUN = mean, trim = 0.1 will use the 10 percent trimmed arithmetic mean instead of the median for comparisons).
Value
PEM
Percent exceeding the median.
test
A list of results from the binomial- and chi-square test.
decreasing
Logical argument from function call (see Arguments above).
# NOT RUN {## Calculate the PEM including the Binomial and Chi-square tests for a single-casedat <- rSC(5, d.level = 0.5)
pem(dat, chi.test = TRUE)
# }