Title: | Functions to Analyze Single System Data |
---|---|
Description: | Functions to visually and statistically analyze single system data. |
Authors: | Charles Auerbach [aut, cre], Wendy Zeitlin [aut] |
Maintainer: | Charles Auerbach <[email protected]> |
License: | GPL (>= 2) |
Version: | 1.5.37 |
Built: | 2024-12-16 23:36:58 UTC |
Source: | CRAN |
Computes one-way ANOVA and performs Tukey multiple comparison post-hoc test. Use ANOVA instead of a t-test when comparing more than two phases.
ABanova(behavior, phaseX)
ABanova(behavior, phaseX)
behavior |
behavior variable |
phaseX |
phase variable |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data, 2nd ed. Oxford University Press, 2022. p91, p112-116, p191
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABanova(cry,pcry)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABanova(cry,pcry)
This function enables users to draw an arrow on a graph. For example, an arrow can be drawn from a text label of a critical event to a point on the graph.
ABarrow()
ABarrow()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data 2nd ed. Oxford University Press, 2022. p180, p186
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run ABarrow()
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run ABarrow()
This function tests for autocorrelation for any lag. Should be used with samples greater than or equal to six. Also produces significance graph for lags. The Box-Ljung test of significance is performed for all lags up to and including the specified one.
ABautoacf(behavior, phaseX, v, l)
ABautoacf(behavior, phaseX, v, l)
behavior |
behavior variable |
phaseX |
phase variable |
v |
letter for phase tested (e.g., "A") |
l |
number of lags (e.g. 1, 2, 3) |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p42 ,p141
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABautoacf(cry, pcry, "B", 2)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABautoacf(cry, pcry, "B", 2)
This function tests for partial autocorrelation for any lag. Should be used with samples greater than or equal to six. Also produces significance graph for lags. The Box-Ljung test of significance is performed for all lags up to and including the specified one.
ABautopacf(behavior, phaseX, v, lags)
ABautopacf(behavior, phaseX, v, lags)
behavior |
behavior variable |
phaseX |
phase variable |
v |
letter for phase being tested (e.g.,"A") |
lags |
number of lags (e.g., 1, 2, 3) |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABautopacf (cry, pcry,"A", 3)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABautopacf (cry, pcry,"A", 3)
Binomial test comparing the number of observations of a phase in a desired zone to another phase. User needs to select method for defining a desired zone (e.g., below one SD).
ABbinomial(phaseX, v1, v2, successA, successB)
ABbinomial(phaseX, v1, v2, successA, successB)
phaseX |
phase variable |
v1 |
letter of first phase (e.g.,"A") |
v2 |
letter of second phase (e.g., "B") |
successA |
occurrences in desired zone for first phase |
successB |
occurrences in desired zone for second phase |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p143
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD1(cry,pcry,"A","week","amount","Crying") ABbinomial(pcry,"A","B1", 1, 8)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD1(cry,pcry,"A","week","amount","Crying") ABbinomial(pcry,"A","B1", 1, 8)
This function produces descriptive statistics for all phases. Statistics produced are: mean, 10 percent trimmed mean, median, standard deviation (sd), coefficient of variation (CV), range, interquartile range, and quantiles. Graphical output for this function is a boxplot of data in each phase.
ABdescrip(behavior, PhaseX)
ABdescrip(behavior, PhaseX)
behavior |
behavior variable |
PhaseX |
phase variable |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p32, p44, p49, p98, p109, p134
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # ABdescrip(cry,pcry)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # ABdescrip(cry,pcry)
Builds an iqr band graph through all phases based upon the user's selection of a phase
ABiqr(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
ABiqr(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of phase statistics are based upon in quotation marks |
ABxlab |
label for x-axis in quotation markes |
ABylab |
label for y-axis in quotation marks |
ABmain |
main title in quotation marks |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p133
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # ABiqr(cry,pcry,"week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # ABiqr(cry,pcry,"week","amount","Crying")
Enables the user to draw dashed vertical lines between phases on a graph.
ABlineD(behavior)
ABlineD(behavior)
behavior |
behavior variable |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p96
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run ABlineD(cry)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run ABlineD(cry)
This function enables the user to draw solid vertical lines between phases on a graph.
ABlines(behavior)
ABlines(behavior)
behavior |
behavior variable |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p46, p50, p51, p60, p61, p71, p75, p76, p79, p105, p108, p129
Go to www.ssdanlysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run ABlines(cry)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run ABlines(cry)
Creates moving average transformation using every two observations. A graph is produced and the user is given the option to save the transformed data.
ABma(behavior, phaseX, v1)
ABma(behavior, phaseX, v1)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of phase to be transformed (e.g.,"A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p38-39, p67, p142
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABma(cry, pcry, "A")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABma(cry, pcry, "A")
This function builds a simple line graph for a given behavior across all phases. A space separates each phase.
ABplot(behavior, phaseX, ABxlab, ABylab, ABmain)
ABplot(behavior, phaseX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
ABxlab |
label for x-axis between quotation marks |
ABylab |
label for y-axis between quotation marks |
ABmain |
main title for graph between quotation marks |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p46, p48,p50, p108,p128
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # ABplot(cry,pcry,"week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # ABplot(cry,pcry,"week","amount","Crying")
This function should be used to create multiple line charts. This function must be used after the environment is set up using the plotnum() function.
ABplotm(behavior, phaseX, ABxlab, ABylab, ABmain)
ABplotm(behavior, phaseX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
ABxlab |
label for x-axis between quotation marks |
ABylab |
label for y-axis between quotation marks |
ABmain |
main title for graph between quotation marks |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p108, p129
Go to www.analysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") yell<-c(3, 4, 2, 5, 5, 4, NA, 1, 2, 2, 2, 0, 0) pyell<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B") plotnum(2, 1) ABplotm(cry,pcry,"week","amount","Crying") ABplotm(yell,pyell,"week","amount","Yelling")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") yell<-c(3, 4, 2, 5, 5, 4, NA, 1, 2, 2, 2, 0, 0) pyell<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B") plotnum(2, 1) ABplotm(cry,pcry,"week","amount","Crying") ABplotm(yell,pyell,"week","amount","Yelling")
Conducts OLS regression comparing any two phases. Coefficients and residuals are produced for each phase. Also a graph with a regression line is displayed for each phase in the graph window.
ABregres(behavior, phaseX, v1, v2)
ABregres(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
CCharles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p52, p53, p54, p135
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABregres(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABregres(cry,pcry,"A","B")
This function tests for lag-1 autocorrelation. This should be used any time the sample size is less than six. Any phase can be tested. Also produces regression line graph.
ABrf2(behavior, phaseX, v1)
ABrf2(behavior, phaseX, v1)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of phase being tested (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Huitema, B.F. & McKean, J.W. (1994). Two reduced-biased autocorrelation estimators: rF1 and rF2. Perceptual and Motor Skills, 78(1), 323-330.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p18, p37-41, p65, p66, p141
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABrf2(cry, pcry, "B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABrf2(cry, pcry, "B1")
Uses MASS package developed by Brian Ripley <[email protected]> to conduct robust regression comparing any two phases. Coefficients and residuals are produced for each phase. Also a graph with a regression line is displayed for each phase in the graph window.
ABrobust(behavior, phaseX, v1, v2)
ABrobust(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of first phase in quotation marks (e.g., "A") |
v2 |
letter of second phase in quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p135
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABrobust(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABrobust(cry,pcry,"A","B")
Add a mean and/or median line to an ABplot.
ABstat(behavior, phaseX, v, statX)
ABstat(behavior, phaseX, v, statX)
behavior |
behavior variable |
phaseX |
phase variable |
v |
phase letter in quotation marks (e.g., "A") |
statX |
statistic in quotation marks (i.e. "mean", "median") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p48, p50, p51, p138
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run this ABplot(cry,pcry,"week","amount","Crying") # run this statement ABstat(cry, pcry, "A", "median")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run this ABplot(cry,pcry,"week","amount","Crying") # run this statement ABstat(cry, pcry, "A", "median")
Add text to graphs. Text must appear between quotation marks.
ABtext(textx)
ABtext(textx)
textx |
text string must be entered between quotation marks (e.g., "baseline") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p30, p46, p47, p48, p50, p51, p60, p61, p71, p73, p75
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # run this ABplot(cry,pcry,"week","amount","Crying") # now run ABtext("A")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # run this ABplot(cry,pcry,"week","amount","Crying") # now run ABtext("A")
This function builds a time series chart for a given behavior across all phases. A space separates each phase. There are no connecting dots.
ABtsplot(behavior, phaseX, ABxlab, ABylab, ABmain)
ABtsplot(behavior, phaseX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
ABxlab |
label for x-axis between quotation marks (e.g., "week") |
ABylab |
label for y-axis between quotation marks (e.g., "amount") |
ABmain |
main title graph between quotation mark (e.g., "Crying") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABtsplot(cry,pcry,"week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABtsplot(cry,pcry,"week","amount","Crying")
Computes t-test comparing any twp phases selected by user. Bar graph displaying means for each phase is displayed in the graph window.
ABttest(behavior, phaseX, v1, v2)
ABttest(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of first phase (e.g., "A") |
v2 |
letter of second phase (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p87, p91, p146-147
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABttest(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABttest(cry,pcry,"A","B")
Performs a two-sample Wilcoxon rank-sum nonparametric test between any two phases.
ABWilcox(behavior, phaseX, v1, v2)
ABWilcox(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p147
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABWilcox(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABWilcox(cry,pcry,"A","B")
This function combines data files. This is useful after data are created during transformations when using the diffchart or ABma functions. Once files with different phases are combined, you can use the saved file for significance testing.
Append()
Append()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p67, p91, p143
Go to www.ssdanalysis.com for more information.
# type Append()
# type Append()
Conducts OLS regression for any phase. Coefficients and residuals are produced. Also a simple line graph for the specified phase with a regression line is displayed in the graph window.
Aregres(behavior, phaseX, v1)
Aregres(behavior, phaseX, v1)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p34, p35-36, p134
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Aregres(cry,pcry,"A")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Aregres(cry,pcry,"A")
Differencing in any phase. Graphs display both original data and differenced data.
Arimadiff(behavior, phaseX, v, d)
Arimadiff(behavior, phaseX, v, d)
behavior |
behavior variable |
phaseX |
phase variable |
v |
phase letter in quotation marks (e.g., "A") |
d |
integer for order of difference |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p142
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Arimadiff(cry,pcry,"B1",2)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Arimadiff(cry,pcry,"B1",2)
Moving average over any period for ARIMA. Uses TTR Package.
Arimama(behavior, phaseX, v, m)
Arimama(behavior, phaseX, v, m)
behavior |
behavior variable |
phaseX |
phase variable |
v |
phase letter in quotation markse (e.g., "A") |
m |
number of periods to average over (e.g., 2) |
CCharles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p142-143
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Arimama(cry,pcry,"B1",2)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Arimama(cry,pcry,"B1",2)
Uses MASS package developed by Brian Ripley <[email protected]> to conduct robust regression for a single phase. Coefficients and residuals are produced. Also a graph with a regression line is displayed for the phase in the graph window.
Arobust(behavior, phaseX, v1)
Arobust(behavior, phaseX, v1)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p143
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Arobust(cry,pcry,"A")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Arobust(cry,pcry,"A")
This function builds a C-chart and is used with individual (i.e., ungrouped) data. A space separates each phase. For use when the outcome variable is a count (i.e., ratio-level) variable.
Cchart(behavior, phaseX, v1, bandX, ABxlab, ABylab, ABmain)
Cchart(behavior, phaseX, v1, bandX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter analysis is based upon in quotation marks (e.g., "A") |
bandX |
number of standard deviations desired (e.g., 2) |
ABxlab |
label for x-axis between quotation marks (e.g., "weeks") |
ABylab |
label for y-axis between quotation marks (e.g., "amount") |
ABmain |
main title between quotation marks (e.g., Crying) |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p77, p140
Bloom, M., Fischer, J. & Orme, J.G. (2009). Evaluating practice: Guidelines for the accountable professional (6th ed.). New York: Pearson.
Orme, J. & Cox, M.E. (2001). Analyzing single-subject design data using statistical proces control charts. Social Work Research, 25(2), 115-127.
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Cchart(cry,pcry,"A",2,"week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Cchart(cry,pcry,"A",2,"week","amount","Crying")
The conservative dual-criteria (CDC) is a relatively new approach to comparing phases that works well when data have a moderate lag-1 autocorrelation (lower than 0.6). This function uses two lines to define the desired zone: the mean and the regression line of the comparison phase.
CDCabove(behavior, phaseX, v1, v2)
CDCabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter of first (i.e., comparison) phase between quotation marks (e.g., "A") |
v2 |
phase letter of second phase between quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p85, p143
Fisher, W.W., Kelley, M.E. & Lomas, J.E. (2003). Visual aids and structured criteria for improving visual inspection and interpretation of single-case designs. Journal of Applied Behavior Analysis, 36(3), 387-406.
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") CDCabove(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") CDCabove(cry,pcry,"A","B")
The conservative dual-criteria (CDC) is a relatively new approach to comparing phases that works well when data have a moderate lag-1 autocorrelation (lower than 0.6). This function uses two lines to define the desired zone: the mean and the regression line of the comparison phase.
CDCbelow(behavior, phaseX, v1, v2)
CDCbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter of first (i.e., comparison) phase between quotation marks (e.g., "A") |
v2 |
phase letter of second phase between quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p85, p143
Fisher, W.W., Kelley, M.E. & Lomas, J.E. (2003). Visual aids and structured criteria for improving visual inspection and interpretation of single-case designs. Journal of Applied Behavior Analysis, 36(3), 387-406.
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") CDCbelow(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") CDCbelow(cry,pcry,"A","B")
Produces first difference transformation on any phase.
diffchart(behavior, phaseX, v1)
diffchart(behavior, phaseX, v1)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter for phase to be transformed between quotation marks (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p39, p40, p65-66, p90, p142
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") diffchart(cry,pcry,"A")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") diffchart(cry,pcry,"A")
The effect size function automatically displays the percent change and calculated values for both the ES and d-index for any two phases. Information for interpretting calculated values appears in the Console.
Effectsize(behavior, phaseX, v1, v2)
Effectsize(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter between quotation marks (e.g., "A") |
v2 |
second phase letter between quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p56-57, p103, p135
Cohen, J.(1988).Statistical Power analysis for the behavioral sciences (2nd ed). Hillsdale, NJ: Lawrence Erlbaum Associates, Inc.
Glass, G. V., McGaw, B., & Smith, M. L. (1981) Meta-analysis in social research. Thousand Oaks, CA: SAGE Publications, Inc.
Bloom, M., Fischer, J. & Orme, J.G. (2009). Evaluating practice: Guidelines for the accountable professional (6th ed.). New York: Pearson.
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Effectsize(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Effectsize(cry,pcry,"A","B")
This function tests for lag-1 autocorrelation for group data. This should be used any time the sample size is less than six. Any phase can be tested. Also produces regression line graph.
GABrf2(behavior, phaseX, timeX, v1)
GABrf2(behavior, phaseX, timeX, v1)
behavior |
behavior variable |
phaseX |
phase variable |
timeX |
time variable (e.g., week) |
v1 |
letter of phase being tested in quotation marks (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p99, p101, p147
Huitema, B.F. & McKean, J.W. (1994). Two reduced-biased autocorrelation estimators: rF1 and rF2. Perceptual and Motor Skills, 78(1), 323-330.
Go to www.ssdanalysis.com for more information.
attend<-c(0,0,0,1,0,0,1,0,0,1,0,0,1,0,1,0,0,0,0,0,1,1,0,0,1,NA, 0,1,1,0,1,1,0,1,1,1,0,1,0,0,1,1,1,1,0,0,1,1,0,1,0,1,1,1,1,1,1,1, 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) week<-c(1,1,1,1,1,2,2,2,2,2,3,3,3,3,3,4,4,4,4,4,5,5,5,5,5,NA,6,6,6,6,6,7,7,7,7,7, 8,8,8,8,8,9,9,9,9,9,10,10,10,10,10,11,11,11,11,11,12,12,12,12,12,13, 13,13,13,13,14,14,14,14,14,15,15,15,15,15) pattend<-c("A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A", "A","A","A",NA,"B","B","B","B","B","B","B","B","B","B","B","B","B","B","B" ,"B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B","B","B","B","B","B","B") # now run: GABrf2(attend,pattend,week,"A")
attend<-c(0,0,0,1,0,0,1,0,0,1,0,0,1,0,1,0,0,0,0,0,1,1,0,0,1,NA, 0,1,1,0,1,1,0,1,1,1,0,1,0,0,1,1,1,1,0,0,1,1,0,1,0,1,1,1,1,1,1,1, 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) week<-c(1,1,1,1,1,2,2,2,2,2,3,3,3,3,3,4,4,4,4,4,5,5,5,5,5,NA,6,6,6,6,6,7,7,7,7,7, 8,8,8,8,8,9,9,9,9,9,10,10,10,10,10,11,11,11,11,11,12,12,12,12,12,13, 13,13,13,13,14,14,14,14,14,15,15,15,15,15) pattend<-c("A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A", "A","A","A",NA,"B","B","B","B","B","B","B","B","B","B","B","B","B","B","B" ,"B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B","B","B","B","B","B","B") # now run: GABrf2(attend,pattend,week,"A")
Computes t-test for group data. A bar graph showing the mean for each phase is displayed.
GABttest(behavior, phaseX, timeX, v1, v2)
GABttest(behavior, phaseX, timeX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
timeX |
time variable (e.g., week) |
v1 |
first phase letter between quotation marks (e.g., "A") |
v2 |
second phase letter between quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p104, p108
Go to www.ssdanalysis.com for more information.
attend<-c(0,0,0,1,0,0,1,0,0,1,0,0,1,0,1,0,0,0,0,0,1,1,0,0,1,NA, 0,1,1,0,1,1,0,1,1,1,0,1,0,0,1,1,1,1,0,0,1,1,0,1,0,1,1,1,1,1,1,1, 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) week<-c(1,1,1,1,1,2,2,2,2,2,3,3,3,3,3,4,4,4,4,4,5,5,5,5,5,NA,6,6, 6,6,6,7,7,7,7,7, 8,8,8,8,8,9,9,9,9,9,10,10,10,10,10,11,11,11,11,11,12, 12,12,12,12,13, 13,13,13,13,14,14,14,14,14,15,15,15,15,15) pattend<-c("A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A", "A","A","A",NA,"B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B","B","B" ,"B","B","B","B") # now run GABttest(attend, pattend, week, "A", "B")
attend<-c(0,0,0,1,0,0,1,0,0,1,0,0,1,0,1,0,0,0,0,0,1,1,0,0,1,NA, 0,1,1,0,1,1,0,1,1,1,0,1,0,0,1,1,1,1,0,0,1,1,0,1,0,1,1,1,1,1,1,1, 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) week<-c(1,1,1,1,1,2,2,2,2,2,3,3,3,3,3,4,4,4,4,4,5,5,5,5,5,NA,6,6, 6,6,6,7,7,7,7,7, 8,8,8,8,8,9,9,9,9,9,10,10,10,10,10,11,11,11,11,11,12, 12,12,12,12,13, 13,13,13,13,14,14,14,14,14,15,15,15,15,15) pattend<-c("A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A", "A","A","A",NA,"B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B","B","B" ,"B","B","B","B") # now run GABttest(attend, pattend, week, "A", "B")
Imports .csv file created in any software package. Uses dialogue box to acquire file. IMPORTANT NOTE: After the file is open type 'attach(ssd)' in the Console and press <RETURN> to manipulate file. Also, can type 'listnames()' to review variable names. Before you open another file type 'detach(ssd)' in the console and press <RETURN>.
Getcsv()
Getcsv()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p22, p29, p44, p66, p90, p91, pp95, p128
Go to www.ssdanalysis.com for more information.
# type Getcsv()
# type Getcsv()
The g-index is a measure of effect size calculated using the proportion of scores in the desired zone. Used when there is a trend in the data.
Gindex(behavior, phaseX, v1, v2)
Gindex(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter between quotation marks (e.g., "A") |
v2 |
second phase letter between quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p57-59
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Gindex(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Gindex(cry,pcry,"A","B")
Draws a goal line
Gline()
Gline()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p22, p29, p44, p66, p90, p91, pp95, p128
Go to www.ssdanalysis.com for more information.
# type Getcsv()
# type Getcsv()
Places median line for baseline in group boxplot.
Gmedian(behavior, phaseX, v)
Gmedian(behavior, phaseX, v)
behavior |
behavior variable |
phaseX |
phase variable |
v |
phase letter for baseline (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p96, p148
Go to www.ssdanalysis.com for more information.
cohesion<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83, 82,89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA,86,87,88,89,79,73,75, 74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49, 48,50,46,55,51,55,49,50,48,51,33) week<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11,12, 12,12,12,12,12,12) pcohesion<-c("A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA,"B","B","B", "B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B") ABdescrip(cohesion,week) Gmedian(cohesion,pcohesion,"A")
cohesion<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83, 82,89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA,86,87,88,89,79,73,75, 74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49, 48,50,46,55,51,55,49,50,48,51,33) week<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11,12, 12,12,12,12,12,12) pcohesion<-c("A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA,"B","B","B", "B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B") ABdescrip(cohesion,week) Gmedian(cohesion,pcohesion,"A")
Insert function - this function is not in use by SSD for R end-users.
insert(v, e, pos)
insert(v, e, pos)
v |
not used |
e |
not used |
pos |
not used |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information.
# This function is not in use by SSD for R end-users.
# This function is not in use by SSD for R end-users.
Draws an interquartile band graph for any phase.
IQRbandgraph(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
IQRbandgraph(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter for phase for which bands will be drawn (e.g., "A") |
ABxlab |
label for x-axis in quotation marks (e.g., "weeks") |
ABylab |
lable for y-axis in quotation marks (e.g., "amount") |
ABmain |
main title for graph in quotation marks (e.g., "Crying") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p133
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") IQRbandgraph(cry,pcry,"A","week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") IQRbandgraph(cry,pcry,"A","week","amount","Crying")
This function creates a legend on an IQR band graph. NOTE: Once this legend is in place, the graph can no longer be altered.
IQRlegend()
IQRlegend()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p133
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") IQRbandgraph(cry,pcry,"A","week","amount","Crying") IQRlegend()
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") IQRbandgraph(cry,pcry,"A","week","amount","Crying") IQRlegend()
This function enables a user to add lines representing the interquartile range to any phase of an ABplot.
IQRline(behavior, phaseX, v)
IQRline(behavior, phaseX, v)
behavior |
behavior variable |
phaseX |
phase variable |
v |
phase letter upon which IQR stats are based - in quotation marks (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p50, p131
Go www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABplot(cry,pcry,"week","amount","Crying") # type IQRline(cry, pcry, "A")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABplot(cry,pcry,"week","amount","Crying") # type IQRline(cry, pcry, "A")
This effect size function will compute the IRD and display a graph in the graph window.The desired improvemment is an increase in the baseline behavior.
IRDabove(behavior, phaseX, v1, v2)
IRDabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p62-65, p136
Bloom, M., Fischer, J. & Orme, J.G. (2009). Evaluating practice: Guidelines for the accountable professional (6th ed.). New York: Pearson.
Parker, R. I., Vannest, K. J., & Brown, L. (2009). The improvement rate difference for single-case research. Exceptional Children, 75(2), 135-150.
Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") IRDabove(esteem,pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") IRDabove(esteem,pesteem,"A","B1")
This effect size function will compute the IRD and display a graph in the graph window. The desired improvemment is a decrease in the baseline behavior.
IRDbelow(behavior, phaseX, v1, v2)
IRDbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p62-65, p136
Bloom, M., Fischer, J. & Orme, J.G. (2009). Evaluating practice: Guidelines for the accountable professional (6th ed.). New York: Pearson.
Parker, R. I., Vannest, K. J., & Brown, L. (2009). The improvement rate difference for single-case research. Exceptional Children, 75(2), 135-150. Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") #IQRbandgraph(cry,pcry,"A","week","amount","Crying") IRDbelow(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") #IQRbandgraph(cry,pcry,"A","week","amount","Crying") IRDbelow(cry,pcry,"A","B")
Lists variable names in active data.
listnames()
listnames()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p22, p71, p74, p95, p128
Go to www.ssdanalysis.com for more information.
# type: listnames()
# type: listnames()
Chi-square test comparing the frequency of observations above the reference phase mean in any two phases.
meanabove(behavior, phaseX, v1, v2)
meanabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") meanabove(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") meanabove(cry,pcry,"A","B1")
Chi-square test comparing the frequency of observations below the reference phase mean in any two phases.
meanbelow(behavior, phaseX, v1, v2)
meanbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") meanbelow(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") meanbelow(cry,pcry,"A","B1")
This function calculates a mean and SD for Cohen's D effect sizes. A file containing saved effect sizes must be opened by Getcvs() and then attached.
meanES(es, lab, esmain)
meanES(es, lab, esmain)
es |
effect size variable |
lab |
Label variable |
esmain |
main title for graph between quotation marks |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p46, p48,p50, p108,p128
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
#need to open a file
#need to open a file
This function calculates a mean and SD for a file containing NAP effect sizes A file containing saved effect sizes must be opened by Getcvs() and then attached.
meanNAP(es, lab, esmain)
meanNAP(es, lab, esmain)
es |
effect size variable |
lab |
Label variable |
esmain |
main title for graph between quotation marks |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p46, p48,p50, p108,p128
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
#need to open a file
#need to open a file
Chi-square test comparing the frequency of observations above the reference phase median in any two phases.
medabove(behavior, phaseX, v1, v2)
medabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") medabove(esteem, pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") medabove(esteem, pesteem,"A","B1")
Chi-square test comparing the frequency of observations below the reference phase median in any two phases.
medbelow(behavior, phaseX, v1, v2)
medbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p84, p144
Go to www.ssdanalyis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") medbelow(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") medbelow(cry,pcry,"A","B1")
Meta regression for saved effect sizes in SSDforR. Use the Getcsv() function to open the saved effect size file.
#metareg(es, v)
#metareg(es, v)
es |
effect size variable |
v |
variance of effect size |
Charles Auerbach, PhD & Wendy Zeitlin, PhD; Yeshiva University, Wurzweiler School of Social Work
Go to www.ssdanalysis.com for more information.
Del Re, A. C. (2015). A practical tutorial on conducting meta-analysis in R. The Quantitative Methods for Psychology, 11(1), 37-50.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014.
ES<-c(.3, .4, .2, .5, .3, .4) V<-c(.01, .03, .04, .02, .03, .02) metareg(ES,V)
ES<-c(.3, .4, .2, .5, .3, .4) V<-c(.01, .03, .04, .02, .03, .02) metareg(ES,V)
Meta regression for saved effect sizes in SSDforR. Use the Getcsv() function to open the saved effect size file.
metaregi(es, i, v)
metaregi(es, i, v)
es |
effect size variable |
i |
moderator |
v |
variance of effect size |
Charles Auerbach, PhD & Wendy Zeitlin, PhD; Yeshiva University, Wurzweiler School of Social Work
Go to www.ssdanalysis.com for more information.
Del Re, A. C. (2015). A practical tutorial on conducting meta-analysis in R. The Quantitative Methods for Psychology, 11(1), 37-50.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014.
ES<-c(.3, .4, .2, .5, .3, .4) V<-c(.01, .03, .04, .02, .03, .02) I<-c(1,3,5,4,6,7) metaregi(ES,I,V)
ES<-c(.3, .4, .2, .5, .3, .4) V<-c(.01, .03, .04, .02, .03, .02) I<-c(1,3,5,4,6,7) metaregi(ES,I,V)
This effect size function will compute the NAP. The desired improvemment is an increase in the baseline behavior.
NAPabove(behavior, phaseX, v1, v2)
NAPabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p62-65, p136
Bloom, M., Fischer, J. & Orme, J.G. (2009). Evaluating practice: Guidelines for the accountable professional (6th ed.). New York: Pearson.
Parker, R. I., & Vannest, K. (2009). An improved effect size for single-case research: Nonoverlap of all pairs. Behavior Therapy, 40(4), 357-367.
Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") NAPabove(esteem,pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") NAPabove(esteem,pesteem,"A","B1")
This effect size function will compute the NAP. The desired improvemment is an decreas in the baseline behavior.
NAPbelow(behavior, phaseX, v1, v2)
NAPbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p62-65, p136
Bloom, M., Fischer, J. & Orme, J.G. (2009). Evaluating practice: Guidelines for the accountable professional (6th ed.). New York: Pearson.
Parker, R. I., & Vannest, K. (2009). An improved effect size for single-case research: Nonoverlap of all pairs. Behavior Therapy, 40(4), 357-367.
Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") NAPbelow(esteem,pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") NAPbelow(esteem,pesteem,"A","B1")
This effect size function evaluates the percentage of all non-overlapping Data (PAND) above the reference line in the comparison phase. Users will be prompted to enter a value for the reference line.
PANDabove(behavior, phaseX, v1, v2)
PANDabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p62 p136
Lenz, A.S. (2012). Calculating effect size in single-case research: A comparison of nonoverlap methods. Measurement and Evaluation in Counseling and Development, 46(1), 64-73.
Parker, R.I. & Hagan-Burker, S. & Vannest, K. (2007). Percentage of all non-overlapping data: An alternative to PND. The Journal of Special Education, 40(4), 194-204.
Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PANDabove(esteem,pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PANDabove(esteem,pesteem,"A","B1")
This effect size function evaluates the percentage of all non-overlapping Data (PAND) above the reference line in the comparison phase. Users will be prompted to enter a value for the reference line.
PANDbelow(behavior, phaseX, v1, v2)
PANDbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase variable (e.g., "A") |
v2 |
second phase variable (e.g., "B") |
Charles Auerbach, PhD & Wendy Zeitlin, PhD; Yeshiva University, Wurzweiler School of Social Work
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p62, p136
Lenz, A.S. (2012). Calculating effect size in single-case research: A comparison of nonoverlap methods. Measurement and Evaluation in Counseling and Development, 46(1), 64-73.
Parker, R.I. & Hagan-Burker, S. & Vannest, K. (2007). Percentage of all non-overlapping data: An alternative to PND. The Journal of Special Education, 40(4), 194-204.
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PANDbelow(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PANDbelow(cry,pcry,"A","B1")
Adds a legend to PAND graph. The graph can not be modified in any way after the legend is added.
PANDlegend()
PANDlegend()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p136
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PANDbelow(cry,pcry,"A","B1") PNDlegend()
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PANDbelow(cry,pcry,"A","B1") PNDlegend()
This function builds a P-chart and can be used when the target behavior has a binary outcome. This chart allows for a comparison of the proportion of tasks completed over time or between phases. A space separates each phase.
Pchart(behavior, groupX, bandX, ABxlab, ABylab, ABmain)
Pchart(behavior, groupX, bandX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
groupX |
grouping variable |
bandX |
number of standard deviations desired (e.g., 2) |
ABxlab |
label for x-axis between quotation marks (e.g., "weeks") |
ABylab |
label for y-axis between quotation marks (e.g., "attendance"") |
ABmain |
main title for chart between quotation marks (e.g., "Attendance Over Time") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p75, p139-140
Orme, J. & Cox, M.E. (2001). Analyzing single-subject design data using statistical proces control charts. Social Work Research, 25(2), 115-127.
Go to www.ssdanalysis.com for more information.
attend<-c(0,0,0,1,0,0,1,0,0,1,0,0,1,0,1,0,0,0,0,0,1,1,0,0,1,NA, 0,1,1,0,1,1,0,1,1,1,0,1,0,0,1,1,1,1,0,0,1,1,0,1,0,1,1,1,1,1,1,1, 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) day<-c(1,1,1,1,1,2,2,2,2,2,3,3,3,3,3,4,4,4,4,4,5,5,5,5,5,NA,6,6, 6,6,6,7,7,7,7,7, 8,8,8,8,8,9,9,9,9,9,10,10,10,10,10,11,11,11,11, 11,12,12,12,12,12,13, 13,13,13,13,14,14,14,14,14,15,15,15,15,15) Pchart(attend, day, 2, "week", "amount", "Group attendance")
attend<-c(0,0,0,1,0,0,1,0,0,1,0,0,1,0,1,0,0,0,0,0,1,1,0,0,1,NA, 0,1,1,0,1,1,0,1,1,1,0,1,0,0,1,1,1,1,0,0,1,1,0,1,0,1,1,1,1,1,1,1, 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) day<-c(1,1,1,1,1,2,2,2,2,2,3,3,3,3,3,4,4,4,4,4,5,5,5,5,5,NA,6,6, 6,6,6,7,7,7,7,7, 8,8,8,8,8,9,9,9,9,9,10,10,10,10,10,11,11,11,11, 11,12,12,12,12,12,13, 13,13,13,13,14,14,14,14,14,15,15,15,15,15) Pchart(attend, day, 2, "week", "amount", "Group attendance")
Percentage of Data Exceeding the Median (PEM). The PEM procedure offers a method to assess effect size and adjust for the influence of outliers in the baseline phase when desired values are above the reference line.
PEMabove(behavior, phaseX, v1, v2)
PEMabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase variable (e.g., "A") |
v2 |
second phase variable (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p60, p137
Lenz, A.S. (2012). Calculating effect size in single-case research: A comparison of nonoverlap methods. Measurement and Evaluation in Counseling and Development, 46(1), 64-73.
Ma, H-H. (2009). The effectiveness of intervention on the behavior of individuals with autism: A meta-analysis using percentage of data points exceeding the median of baseline phase. Behavior Modification, 33(3), 339-359.
Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PEMabove(esteem,pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PEMabove(esteem,pesteem,"A","B1")
Percentage of Data Exceeding the Median (PEM). The PEM procedure offers a method to assess effect size and adjust for the influence of outliers in the baseline phase when desired values are below the reference line.
PEMbelow(behavior, phaseX, v1, v2)
PEMbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
irst phase variable (e.g., "A") |
v2 |
second phase variable (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Lenz, A.S. (2012). Calculating effect size in single-case research: A comparison of nonoverlap methods. Measurement and Evaluation in Counseling and Development, 46(1), 64-73.
Ma, H-H. (2009). The effectiveness of intervention on the behavior of individuals with autism: A meta-analysis using percentage of data points exceeding the median of baseline phase. Behavior Modification, 33(3), 339-359.
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PEMbelow(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PEMbelow(cry,pcry,"A","B")
Adds a legend to a PEM graph. The graph can not be modified in any way after the legend is added.
PEMlegend()
PEMlegend()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") #run first PEMbelow(cry,pcry,"A","B1") #run after complete steps above PEMlegend()
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") #run first PEMbelow(cry,pcry,"A","B1") #run after complete steps above PEMlegend()
Used prior to ABplotm to set up graphic environment.
plotnum(nr, nc)
plotnum(nr, nc)
nr |
number of rows of graphs desired (e.g., 2) |
nc |
number of columns of graphs desired (e.g., 3) |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p107
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") yell<-c(3, 4, 2, 5, 5, 4, NA, 1, 2, 2, 2, 0, 0) pyell<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B") plotnum(2, 1) ABplotm(cry,pcry,"week","amount","Crying") ABplotm(yell,pyell,"week","amount","Yelling")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") yell<-c(3, 4, 2, 5, 5, 4, NA, 1, 2, 2, 2, 0, 0) pyell<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B") plotnum(2, 1) ABplotm(cry,pcry,"week","amount","Crying") ABplotm(yell,pyell,"week","amount","Yelling")
This effect size function evaluates the percentage of non-overlapping data (PND) above highest data point in the comparison phase.
PNDabove(behavior, phaseX, v1, v2)
PNDabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
comparison phase variable (e.g., "A") |
v2 |
letter of second phase (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Lenz, A.S. (2012). Calculating effect size in single-case research: A comparison of nonoverlap methods. Measurement and Evaluation in Counseling and Development, 46(1), 64-73.
Scruggs, T.E. & Mastropieri, M.A. (2012). PND at 25: Past, present, and future trends in summarizing single-subject research. Remedial and Special Education, 34(1), 9-19.
Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PNDabove(esteem, pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PNDabove(esteem, pesteem,"A","B1")
This effect size function evaluates the percentage of non-overlapping data (PND) below the lowest data point in the comparison phase.
PNDbelow(behavior, phaseX, v1, v2)
PNDbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
comparison phase variable (e.g., "A") |
v2 |
second phase variable (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Lenz, A.S. (2012). Calculating effect size in single-case research: A comparison of nonoverlap methods. Measurement and Evaluation in Counseling and Development, 46(1), 64-73.
Scruggs, T.E. & Mastropieri, M.A. (2012). PND at 25: Past, present, and future trends in summarizing single-subject research. Remedial and Special Education, 34(1), 9-19.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p60, p137
Lenz, A.S. (2012). Calculating effect size in single-case research: A comparison of nonoverlap methods. Measurement and Evaluation in Counseling and Development, 46(1), 64-73.
Parker, R.I. & Hagan-Burker, S. & Vannest, K. (2007). Percentage of all non-overlapping data: An alternative to PND. The Journal of Special Education, 40(4), 194-204.
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PNDbelow(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") PNDbelow(cry,pcry,"A","B1")
Adds a legend to a PND graph. The graph can not be modified in any way after the legend is added.
PNDlegend()
PNDlegend()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p62, p136
Parker, R.I. & Hagan-Burker, S. & Vannest, K. (2007). Percentage of all non-overlapping data: An alternative to PND. The Journal of Special Education, 40(4), 194-204.
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") #run first PNDbelow(cry,pcry,"A","B1") #run after complete steps above PNDlegend()
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") #run first PNDbelow(cry,pcry,"A","B1") #run after complete steps above PNDlegend()
The R-Chart is designed to detect changes in variation over time. This is one of two forms of the R-chart and should be used with small samples. This function uses the mean range of samples to track variation.
Rchart(behavior, groupX, bandX, ABxlab, ABylab, ABmain)
Rchart(behavior, groupX, bandX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
groupX |
grouping variables (e.g., day) |
bandX |
number of standard deviations desired (e.g., 2) |
ABxlab |
x-axis label in quotation marks (e.g., "weeks") |
ABylab |
y-axis label in quotation marks (e.g., "amount") |
ABmain |
main title for graph in quotation marks (e.g., "Problem Range") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p73-74, p136, p106-107, p138-139
Orme, J. & Cox, M.E. (2001). Analyzing single-subject design data using statistical proces control charts. Social Work Research, 25(2), 115-127.
Go to www.ssdanalysis.com for more information.
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83, 82,89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89, NA,86,87,88,89,79,73,75,74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51, 49,48,50,46,55,51,55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11, 11,12,12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A", NA,"B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B") Rchart(admit, day, 2, "week", "amount", "Admits to Hospital")
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83, 82,89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89, NA,86,87,88,89,79,73,75,74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51, 49,48,50,46,55,51,55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11, 11,12,12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A", NA,"B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B") Rchart(admit, day, 2, "week", "amount", "Admits to Hospital")
The R-Chart is designed to detect changes in variation over time. This is one of two forms of the R-chart and should be used with samples larger than ten. This function uses the standard deviation of samples to track variation.
Rchartsd(behavior, groupX, bandX, ABxlab, ABylab, ABmain)
Rchartsd(behavior, groupX, bandX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
groupX |
grouping variable (e.g., day) |
bandX |
number of standard deviations desired (e.g., 2) |
ABxlab |
label for x-axis in quotation marks, (e.g., "day") |
ABylab |
label for y-axis in quotation marks (e.g., "amount") |
ABmain |
main title for graph in quotation marks (e.g., "Variation in Admits") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Orme, J. & Cox, M.E. (2001). Analyzing single-subject design data using statistical proces control charts. Social Work Research, 25(2), 115-127.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p76, p109, p139
Go to www.ssdanalysis.com for more information.
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83,82,89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA,86,87,88,89,79,73,75,74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49,48,50,46,55,51,55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11, 12,12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA,"B", "B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B") Rchartsd(admit, day, 2, "week", "amount", "Admits to Hospital")
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83,82,89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA,86,87,88,89,79,73,75,74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49,48,50,46,55,51,55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11, 12,12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA,"B", "B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B") Rchartsd(admit, day, 2, "week", "amount", "Admits to Hospital")
Chi-square test comparing the frequency of observations above the regression line in a comparison phase to another phase.
regabove(behavior, phaseX, v1, v2)
regabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of comparsion phase in quotation marks (e.g., "A") |
v2 |
letter of second phase in quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p84, p1145-146
Go to www.ssddanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") regabove(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") regabove(cry,pcry,"A","B1")
Chi-square test comparing the frequency of observations below the regression line in a comparison phase to another phase.
regbelow(behavior, phaseX, v1, v2)
regbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of comparison phase in quotation marks (e.g., "A") |
v2 |
letter of second phase in quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p83, p146
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") regbelow(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") regbelow(cry,pcry,"A","B1")
This function enables users to draw an arrow on a graph. For example, an arrow can be drawn from a text label of a critical event to a point on the graph. For Use with Rmarkdown.
RMarrow(X1,Y1,X2,Y2)
RMarrow(X1,Y1,X2,Y2)
X1 |
X1 coordinate |
Y1 |
Y1 coordinate |
X2 |
X2 coordinate |
Y2 |
Y2 coordinate |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p46-p50
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run RMarrow(9,10,11,10)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run RMarrow(9,10,11,10)
Draws a goal line for RMarkdown
RMGline(y)
RMGline(y)
y |
ordinate on y axis / goal level |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p22, p29, p44, p66, p90, p91, pp95, p128
Go to www.ssdanalysis.com for more information.
# type Getcsv()
# type Getcsv()
This function enables the user to draw solid vertical lines between phases on a graph. For use with Rmarkdown.
RMlines(behavior,x)
RMlines(behavior,x)
behavior |
behavior variable |
x |
X coordinate |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p46, p50, p51, p60, p61, p71, p75, p76, p79, p105, p108, p129
Go to www.ssdanlysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run RMlines(cry,13.5)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run RMlines(cry,13.5)
Add a mean and/or median line to an ABplot for RMarkdown.
RMstat(behavior, phaseX, v, statX,l)
RMstat(behavior, phaseX, v, statX,l)
behavior |
behavior variable |
phaseX |
phase variable |
v |
phase letter in quotation marks (e.g., "A") |
statX |
statistic in quotation marks (i.e. "mean", "median") |
l |
x ordinate to start line (e.g., 1) |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p48, p50, p51, p138
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run this ABplot(cry,pcry,"week","amount","Crying") # run this statement RMstat(cry, pcry, "A", "median",1)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run this ABplot(cry,pcry,"week","amount","Crying") # run this statement RMstat(cry, pcry, "A", "median",1)
Add text to graphs. Text must appear between quotation marks. For use with Rmarkdown.
RMtext(textx,x,y)
RMtext(textx,x,y)
textx |
text string must be entered between quotation marks (e.g., "baseline") |
x |
X coordinate |
y |
Y coordinate |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p30, p46, p47, p48, p50, p51, p60, p61, p71, p73, p75
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # run this ABplot(cry,pcry,"week","amount","Crying") # now run RMtext("A",10)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # run this ABplot(cry,pcry,"week","amount","Crying") # now run RMtext("A",10)
Chi-square test comparing the frequency of observations above the robust regression line in a comparison phase to another phase.
robregabove(behavior, phaseX, v1, v2)
robregabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of comparsion phase in quotation marks (e.g., "A") |
v2 |
letter of second phase in quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p85, p146
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") robregabove(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") robregabove(cry,pcry,"A","B1")
Chi-square test comparing the frequency of observations below the robust regression line in a comparison phase to another phase.
robregbelow(behavior, phaseX, v1, v2)
robregbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter of comparison phase in quotation marks (e.g., "A") |
v2 |
letter of second phase in quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p85, p146
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") robregbelow(cry,pcry,"A","B1")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") robregbelow(cry,pcry,"A","B1")
The conservative dual-criteria (CDC) is a relatively new approach to comparing phases that works well when data have a moderate lag-1 autocorrelation (lower than 0.6). This function uses two lines to define the desired zone: the mean and the robust regression line of the comparison phase.
RobustCDCabove(behavior, phaseX, v1, v2)
RobustCDCabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter of first (i.e., comparison) phase between quotation marks (e.g., "A") |
v2 |
phase letter of second phase between quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Fisher, W.W., Kelley, M.E. & Lomas, J.E. (2003). Visual aids and structured criteria for improving visual inspection and interpretation of single-case designs. Journal of Applied Behavior Analysis, 36(3), 387-406.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p86, p144 Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") RobustCDCabove(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") RobustCDCabove(cry,pcry,"A","B")
The conservative dual-criteria (CDC) is a relatively new approach to comparing phases that works well when data have a moderate lag-1 autocorrelation (lower than 0.6). This function uses two lines to define the desired zone: the mean and the robust regression line of the comparison phase.
RobustCDCbelow(behavior, phaseX, v1, v2)
RobustCDCbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter of first (i.e., comparison) phase between quotation marks (e.g., "A") |
v2 |
phase letter of second phase between quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Fisher, W.W., Kelley, M.E. & Lomas, J.E. (2003). Visual aids and structured criteria for improving visual inspection and interpretation of single-case designs. Journal of Applied Behavior Analysis, 36(3), 387-406.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p86, p144 Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") RobustCDCbelow(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") RobustCDCbelow(cry,pcry,"A","B")
This function enables users to draw an arrow on a graph. For example, an arrow can be drawn from a text label of a critical event to a point on the graph. For noninteractive use .
RSarrow(X1,Y1,X2,Y2)
RSarrow(X1,Y1,X2,Y2)
X1 |
X1 coordinate |
Y1 |
Y1 coordinate |
X2 |
X2 coordinate |
Y2 |
Y2 coordinate |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Go to www.ssdanalysis.com for more information
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p46-p50
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run RSarrow(9,10,11,10)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run RSarrow(9,10,11,10)
This function enables the user to draw solid vertical lines between phases on a graph. For use nointeractive use.
RSlines(behavior,x)
RSlines(behavior,x)
behavior |
behavior variable |
x |
X coordinate |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p46, p50, p51, p60, p61, p71, p75, p76, p79, p105, p108, p129
Go to www.ssdanlysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run RSlines(cry,13.5)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run ABplot(cry,pcry,"week","amount","Crying") # now run RSlines(cry,13.5)
Noninteractive add a mean and/or median line to an ABplot.
RSstat(behavior, phaseX, v, statX,l)
RSstat(behavior, phaseX, v, statX,l)
behavior |
behavior variable |
phaseX |
phase variable |
v |
phase letter in quotation marks (e.g., "A") |
statX |
statistic in quotation marks (i.e. "mean", "median") |
l |
x ordinate to start line (e.g., 1) |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p48, p50, p51, p138
Auerbach, C. & Schudrich, W. Z. (2013). SSD for R A Comprehensive Statistical Package to Analyze Single-System Data. Research on Social Work Practice, 23(3), 346-353. doi:10.1177/104973153477213
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run this ABplot(cry,pcry,"week","amount","Crying") # run this statement RSstat(cry, pcry, "A", "median",1)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # now run this ABplot(cry,pcry,"week","amount","Crying") # run this statement RSstat(cry, pcry, "A", "median",1)
Add text to graphs. Text must appear between quotation marks.
RStext(textx,x,y)
RStext(textx,x,y)
textx |
text string must be entered between quotation marks (e.g., "baseline") |
x |
X coordinate |
y |
Y coordinate |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p30, p46, p47, p48, p50, p51, p60, p61, p71, p73, p75
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # run this ABplot(cry,pcry,"week","amount","Crying") # now run RStext("A",10)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") # run this ABplot(cry,pcry,"week","amount","Crying") # now run RStext("A",10)
Adds trimmed mean line to ABplot. Click in the phase of the ABplot to add line.
RSTrimline(behavior, phaseX, v,l)
RSTrimline(behavior, phaseX, v,l)
behavior |
behavior variable |
phaseX |
phase variable |
v |
letter of phase for which trimmed mean is desired in quotation marks (e.g., "A") |
l |
start point on x axis |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p48, p130-131
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABplot(cry,pcry,"week","amount","Crying") # now run RSTrimline(cry,pcry,"A",1)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABplot(cry,pcry,"week","amount","Crying") # now run RSTrimline(cry,pcry,"A",1)
Save .csv file edited in SSDforR. Uses dialogue box to save file.
Savecsv()
Savecsv()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p125, p126, p128
Go to www.ssdanalysis.com for more information.
# type Savecsv()
# type Savecsv()
Produces graph for all phases with mean and one standard deviation bands displayed for a comparison phase across all phases. Output in the Console displays the sd, the mean, and values for the sd bands.
SD1(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
SD1(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter for phase variable stats are base upon in quotation marks (e.g., "A") |
ABxlab |
x-axis label in quotation marks (e.g., "week") |
ABylab |
y-axis label in quotation marks (e.g., "amount") |
ABmain |
main title label in quotation marks (e.g., "Crying") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p51, p79, p132 Go to www.ssdanalysis for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD1(cry,pcry,"A","week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD1(cry,pcry,"A","week","amount","Crying")
Produces graph for one phase with mean and one standard deviation bands displayed. Output in the Console displays the sd, the mean, and values for the sd bands.
sd1bandgraph(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
sd1bandgraph(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter (e.g., "A") |
ABxlab |
x-axis label in quotation marks (e.g., "week") |
ABylab |
y-axis label in quotation marks (e.g., "amount") |
ABmain |
main title in quotation marks (e.g., "Crying") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p131
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") sd1bandgraph(cry,pcry,"A","week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") sd1bandgraph(cry,pcry,"A","week","amount","Crying")
Adds legend to SD1 band graph. The graph can not be modified in any way after the legend is added.
SD1legend()
SD1legend()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p132
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD1(cry,pcry,"A","week","amount","Crying") SD1legend()
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD1(cry,pcry,"A","week","amount","Crying") SD1legend()
Produces graph for all phases with mean and two standard deviation bands displayed for a comparison phase across all phases. Output in the Console displays the sd, the mean, and values for the sd bands.
SD2(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
SD2(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
letter for phase variable stats are base upon in quotation marks (e.g., "A") |
ABxlab |
x-axis label in quotation marks (e.g., "week") |
ABylab |
y-axis label in quotation marks (e.g., "amount") |
ABmain |
main title in quotation marks (e.g., "Crying") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p32-133
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD2(cry,pcry,"A","week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD2(cry,pcry,"A","week","amount","Crying")
Produces graph for one phase with mean and two standard deviation bands displayed. Output in the Console displays the sd, the mean, and values for the sd bands.
sd2bandgraph(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
sd2bandgraph(behavior, phaseX, v1, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter (e.g., "A") |
ABxlab |
x-axis label in quotation marks (e.g., "week") |
ABylab |
y-axis label in quotation marks (e.g., "amount") |
ABmain |
main title in quotation marks (e.g., "Crying") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p34, p132
Go www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") sd2bandgraph(cry,pcry,"A","week","amount","Crying")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") sd2bandgraph(cry,pcry,"A","week","amount","Crying")
Adds legend to SD2 band graph. The graph can not be modified in any way after the legend is added.
SD2legend()
SD2legend()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p133
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD2(cry,pcry,"A","week","amount","Crying") SD2legend()
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") SD2(cry,pcry,"A","week","amount","Crying") SD2legend()
Adds standard deviation bands to an ABplot. Click in the phase twice to add upper and lower bands.
SDAband(behavior, phaseX, v, bandX)
SDAband(behavior, phaseX, v, bandX)
behavior |
behavior variable |
phaseX |
phase variable |
v |
phase band is based upon (e.g., "A") |
bandX |
number of standard deviations desired (e.g., 2) |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p131
Go to www.ssdnalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABplot(cry,pcry,"week","amount","Crying") # now run SDAband(cry,pcry,"A",2)
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABplot(cry,pcry,"week","amount","Crying") # now run SDAband(cry,pcry,"A",2)
Converts scientific notation to decimals.
SN(value)
SN(value)
value |
value to be converted from scientific notation |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p81, p147
Go to www.ssdanalysis.com for more information.
SN(2.73e-16)
SN(2.73e-16)
Adds a legend to any of the SPC charts. The chart can not be modified in any way after the legend is added.
SPClegend()
SPClegend()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p71, p73, p75, p76, p77, p105, p06, p141
Go to www.ssdanalysis.com for more information.
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83,82,89,84,89, 91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA, 86,87,88,89,79,73,75,74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49, 48,50,46,55,51,55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11, 12,12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA, "B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B") Rchartsd(admit, day, 2, "week", "amount", "Admits to Hospital") SPClegend()
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83,82,89,84,89, 91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA, 86,87,88,89,79,73,75,74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49, 48,50,46,55,51,55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11, 12,12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA, "B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B","B") Rchartsd(admit, day, 2, "week", "amount", "Admits to Hospital") SPClegend()
This function enables the user to draw solid vertical lines between phases on the SPC R-chart using standard deviation and R-Chart using mean range. The user clicks the mouse on a upper and lower y ordinate.
SPCline()
SPCline()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p73, p106, p139
Go to www.ssdanlysis.com for more information.
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83,82, 89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA,86,87,88,89, 79,73,75,74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49,48,50,46,55,51,55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11,12, 12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA,"B","B", "B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B") Rchart(admit, day, 2, "week", "amount", "Admits to Hospital") # now run SPCline()
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83,82, 89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA,86,87,88,89, 79,73,75,74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49,48,50,46,55,51,55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11,12, 12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA,"B","B", "B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B","B") Rchart(admit, day, 2, "week", "amount", "Admits to Hospital") # now run SPCline()
Lists all the functions available in the SSD for R package.
SSDforR()
SSDforR()
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p18
Go to www.ssdanalysis.com for more information.
SSDforR()
SSDforR()
This Calculates the Tau-U index Parker, Vannest, Davis, & Sauber 2011.
TauUabove(behavior, phaseX, v1, v2)
TauUabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Parker, Vannest, Davis, & Sauber 2011 Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") TauUabove(esteem,pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") TauUabove(esteem,pesteem,"A","B1")
This Calculates the Tau-U index Parker, Vannest, Davis, & Sauber 2011.
TauUbelow(behavior, phaseX, v1, v2)
TauUbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter (e.g., "A") |
v2 |
second phase letter (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Parker, Vannest, Davis, & Sauber 2011 Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") TauUbelow(esteem,pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") TauUbelow(esteem,pesteem,"A","B1")
Conducts a Mann-Kendall trend test for any phase.
trendtest(behavior, phaseX, v1)
trendtest(behavior, phaseX, v1)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase letter (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p34, p35-36, p134
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") trendtest(cry,pcry,"A")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") trendtest(cry,pcry,"A")
Chi-square test comparing the frequency of observations above the reference phase trimmed mean in any two phases.
trimabove(behavior, phaseX, v1, v2)
trimabove(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter in quotation marks (e.g., "A") |
v2 |
second phase letter in quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p84, p145
Go to www.ssdanalysis.com for more information.
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") trimabove(esteem, pesteem,"A","B1")
esteem<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pesteem<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") trimabove(esteem, pesteem,"A","B1")
Chi-square test comparing the frequency of observations below the reference phase trimmed mean in any two phases.
trimbelow(behavior, phaseX, v1, v2)
trimbelow(behavior, phaseX, v1, v2)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
first phase letter in quotation marks (e.g., "A") |
v2 |
second phase letter in quotation marks (e.g., "B") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p84, p145
Go to www.ssdanalysis.com for more information
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") trimbelow(cry,pcry,"A","B")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") trimbelow(cry,pcry,"A","B")
Adds trimmed mean line to ABplot. Click in the phase of the ABplot to add line.
Trimline(behavior, phaseX, v)
Trimline(behavior, phaseX, v)
behavior |
behavior variable |
phaseX |
phase variable |
v |
letter of phase for which trimmed mean is desired in quotation marks (e.g., "A") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p48, p130-131
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABplot(cry,pcry,"week","amount","Crying") # now run Trimline(cry,pcry,"A")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") ABplot(cry,pcry,"week","amount","Crying") # now run Trimline(cry,pcry,"A")
The X-mR-chart can be use to detect changes within and between phases. Can be used with individual data, but it is not appropriate for group data.
Xmrchart(behavior, phaseX, v1, bandX, ABxlab, ABylab, ABmain)
Xmrchart(behavior, phaseX, v1, bandX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
phaseX |
phase variable |
v1 |
phase bands are based upon in quotation marks (e.g., "A") |
bandX |
number of standard deviations desired (e.g., 2) |
ABxlab |
x-axis label in quotation marks (e.g., "week") |
ABylab |
y-axis label in quotation marks (e.g., "amount") |
ABmain |
main title for chart in quotation marks (e.g., "X-mR-Chart") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Bloom, M., Fischer, J. & Orme, J.G. (2009). Evaluating practice: Guidelines for the accountable professional (6th ed.). New York: Pearson.
Orme, J. & Cox, M.E. (2001). Analyzing single-subject design data using statistical proces control charts. Social Work Research, 25(2), 115-127.
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. P75-76
Go to www.ssdanalysis.com for more information.
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Xmrchart(cry, pcry, "A", 2, "week", "amount", "X-mR-Chart")
cry<-c(3, 4, 2, 5, 3, 4, NA, 2, 2, 3, 2, 1, 2, NA, 2, 2, 1, 2, 1, 0, 0, 0) pcry<-c("A", "A", "A", "A", "A", "A", NA, "B", "B", "B", "B", "B", "B", NA, "B1", "B1", "B1", "B1", "B1", "B1", "B1", "B1") Xmrchart(cry, pcry, "A", 2, "week", "amount", "X-mR-Chart")
This chart can be used when there are multiple observations per sample and uses the mean of each sample to create the chart.
XRchart(behavior, groupX, bandX, ABxlab, ABylab, ABmain)
XRchart(behavior, groupX, bandX, ABxlab, ABylab, ABmain)
behavior |
behavior variable |
groupX |
grouping variable |
bandX |
number of standard deviations desired (e.g., 2) |
ABxlab |
x-axis label in quotation marks (e.g., "week") |
ABylab |
y-axis label in quotation marks (e.g., "mean amount") |
ABmain |
main title for chart in quotation marks (e.g., "Admits to Hospital") |
Charles Auerbach, PhD Wurzweiler School of Social Work Wendy Zeitlin, PhD Montclair State University
Auerbach, Charles, and Zeitlin Wendy. SSD for R: An R Package for Analyzing Single-Subject Data. Oxford University Press, 2014. p71, p105
Orme, J. & Cox, M.E. (2001). Analyzing single-subject design data using statistical proces control charts. Social Work Research, 25(2), 115-127.
Go to www.ssdanalysis.com for more information.
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83, 82,89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA,86,87,88,89,79,73,75, 74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49,48,50,46,55,51, 55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11,12, 12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA,"B","B", "B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B") XRchart(admit, day, 2, "week", "amount", "Admits to Hospital")
admit<-c(85,90,80,84,82,79,75,76,80,84,75,80,79,83,88,78,80,85,83, 82,89,84,89,91,87,84,77,86,80, 89,81,86,88,83,86,90,86,85,85,87,80,89,NA,86,87,88,89,79,73,75, 74,70,75,81,85,75,73,75, 79,70,72,71,69,70,64,60,59,54,53,55,50,54,51,49,48,50,46,55,51, 55,49,50,48,51,33) day<-c(1,1,1,1,1,1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,4,4,4,4,4,5, 5,5,5,5,5,5,6,6,6,6,6,6,6,NA,7,7,7,7,7,7,7,8,8,8,8,8,8,8,9, 9,9,9,9,9,9,10,10,10,10,10,10,10,11,11,11,11,11,11,11,12, 12,12,12,12,12,12) padmit<-c("A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A","A","A","A","A","A","A", "A","A","A","A","A","A","A","A","A","A",NA,"B","B", "B","B","B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B", "B","B","B","B","B","B","B","B","B","B","B","B", "B","B","B","B","B","B") XRchart(admit, day, 2, "week", "amount", "Admits to Hospital")