Related Experiment Video
Updated: Jul 6, 2026

Problem-Solving Before Instruction (PS-I): A Protocol for Assessment and Intervention in Students with Different Abilities
Published on: September 11, 2021
SAS macros for testing statistical mediation in data with binary mediators or outcomes
Srichand Jasti1, William N Dudley, Eva Goldwater
1Emma Eccles Jones Nursing Research Center, University of Utah College of Nursing, Salt Lake City, UT 84112, USA. srichand@gmail.com
Background:
Statistical mediation is an important tool in behavioral health sciences, but it has been confined primarily to continuous variables. As prevention studies become increasingly common, more often the mediator or outcome is binary. Recent work by D. P. MacKinnon and J. H. Dwyer (1993) has explicated the steps necessary to estimate models for mediation when the mediator or the outcome is binary.
Objective:
To report the release of a set of SAS macros used to implement the statistical analyses required to analyze data with binary and continuous-level data.
Approach:
A brief introduction to the methodology of mediation analysis in the presence of a binary outcome, mediator, or both is provided. The macros are tested on a sample of 84 participants who were experiencing pain. It is hypothesized that the relationship between pain and fatigue is mediated by sleep disturbance.
Results:
The relationship between pain and fatigue was mediated by the presence of sleep disturbances, and the amount of mediation was 23.34%.
Discussion:
The SAS macros are available for download without charge from the second author's Web site. Instructions are provided in an included technical manual.
Related Concept Videos
Statistical Analysis System (SAS)
Applications: SAS finds applications in numerous fields, including healthcare for clinical trial analysis, finance for risk assessment, marketing for customer data analysis, and...
Statistical Hypothesis Testing
Statistical significance measures the probability that an observed result occurred by chance. If this probability, known as...
One-Way ANOVA: Unequal Sample Sizes
Methods of Medium Optimization
McNemar's Test
One-Way ANOVA: Equal Sample Sizes
Different sample means can result in different values for the variance estimate: variance between samples. This is because the variance between samples is calculated as the product of the sample size and the variance between the...
