Statistical

SAS Statistical Modeling & Analysis: Code Examples for Regression, Survival, and Bayesian Methods

301 Résultats disponibles

Welcome to our dedicated repository for Advanced Statistical Modeling using SAS©. This category is designed for data scientists, biostatisticians, and researchers seeking robust code templates for complex analytical challenges.
This collection covers the full spectrum of statistical methodology, providing you with ready-to-use scripts for:
Handling Missing Data: Robust strategies for multiple imputation using PROC MI and PROC MIANALYZE to ensure data integrity.
Complex Modeling: A wide range of templates for Linear, Non-Linear, and Mixed Models (PROC MIXED, GLIMMIX, NLMIXED).
Survival Analysis: Essential tools for analyzing time-to-event data, including Kaplan-Meier estimates and censored data modeling (PROC LIFETEST, PHREG).
Bayesian Statistics: Implementation of MCMC simulations, prior modeling, and posterior analysis (PROC MCMC, BCHOICE).
Multivariate & Structural Analysis: Scripts for Factor Analysis (PROC FACTOR), Clustering, and Structural Equation Modeling.
Hypothesis Testing: Standard and advanced methods for ANOVA, T-tests, and Power Analysis (PROC POWER, PROC GLM).
Explore these resources to streamline your analytical workflow, validate your hypotheses, and perform rigorous statistical reporting.
Statistical
Weighted Data Analysis: How to Calculate Qualification Rates in SAS CA

This example demonstrates how to use an IF-THEN statement to count credit-qualified individuals, and then how to crea...

View code
Statistical
Realistic Data Imputation: How to Use SAS PROC MI to Fill Gaps without Distorting Your Distribution

This script illustrates the use of the MI procedure to impute missing values in a fish dataset, using a regression me...

View code
Statistical
Fixing Missing Data in SAS: A Guide to Multiple Imputation with PROC MI and MCMC

This script performs multiple imputation on a fitness dataset containing missing values, using the MI procedure with ...

View code
Statistical
Don’t Delete Your Data! How to Use SAS PROC MI to Fix Missing Values Fast

This script illustrates the use of the MI (Multiple Imputation) procedure to impute missing values in a fitness datas...

View code
Statistical
Analyzing Stability Studies: How to Model Batch-to-Batch Variation Using SAS PROC MIXED

Analysis of a random coefficients model using the MIXED procedure to simulate pharmaceutical stability data.

View code
Statistical
The Ultimate SAS MIXED Model Template: Analyzing Crop Yields under Variable Irrigation Levels

This SAS script analyzes data from a sprinkler irrigation experiment using a linear mixed model (PROC MIXED) to evalu...

View code
Statistical
Bayesian Breakpoint Analysis: Detecting Structural Changes in SAS with PROC MCMC

Analyzes a dataset to detect a change point using Bayesian modeling with the MCMC procedure.

View code
Statistical
Stop Fearing Censored Data! The Essential Guide to Bayesian Normal Regression in SAS

This SAS script uses PROC MCMC to perform normal regression with interval censoring.

View code
Statistical
Beyond Imputation: Accounting for Missing Data Uncertainty with SAS PROC MIANALYZE

This script illustrates regression analysis on a dataset with missing values, using multiple imputation (PROC MI) and...

View code
Statistical
High-Performance Logistic Regression: Mastering Binomial Modeling in SAS PROC HPGENSELECT

Example of using PROC HPGENSELECT to model data with a binomial distribution, using the events/trials syntax.

View code
Statistical
Mastering Decision Trees in SAS: A High-Performance Guide to PROC HPSPLIT

Creates a decision tree using the HPSPLIT procedure on randomly generated data to model a binary variable.

View code
Statistical
Mastering Fractional Factorial Designs: Analyzing Aliasing and Confounding in SAS PROC GLM

SAS library example illustrating the use of PROC GLM for the analysis of a screening design (fractional factorial exp...

View code
Statistical
The Ultimate Signal Smoothing Hack: Recovering the Bumps Function using PROC GLMSELECT

This script illustrates the use of PROC GLMSELECT to fit a model with spline effects, using Donoho and Johnstone's 'B...

View code
Statistical
Optimizing Multilevel Logistic Models in SAS: Mastering Quadrature and the FASTQUAD Option

This SAS example illustrates the use of the GLIMMIX procedure for the analysis of generalized mixed models with the q...

View code
Statistical
High-Performance Count Data: Accelerate Your Bayesian Mixture Models in SAS Viya

Example of using the HPFMM procedure to model count data with an excess of zeros (Zero-Inflated) via Poisson regressi...

View code
Statistical
Beyond Basic Poisson: How to Solve the "Excess Zeros" Problem Using SAS Mixture Models

Analysis of count data exhibiting an excess of zeros, using the FMM procedure to fit Poisson regression models, zero-...

View code
Statistical
When One Bell Curve Isn't Enough: Modeling Multimodal Data with SAS PROC FMM

This script performs a statistical analysis on galaxy velocity data using the FMM (Finite Mixture Models) procedure t...

View code
Statistical
Stop Copy-Pasting: Automate PROC FREQ Across Multiple Datasets with One SAS Macro

This SAS script creates two tables (males and females) and uses a macro to perform a frequency analysis (PROC FREQ) o...

View code
Statistical
Comparison of Regression Models with PROC GLM and Macros

This SAS script defines and uses two macros to perform a regression analysis. It creates a dataset, then uses the GLM...

View code
Statistical
Survival Analysis in SAS: A Complete Guide to PROC LIFETEST, Kaplan-Meier, and Life Tables

This SAS script demonstrates several survival analysis techniques using the LIFETEST procedure. It covers the life-ta...

View code
Statistical
Distributional Analysis and Empirical Cumulative Distribution Function (ECDF)

This SAS script defines and uses two macros to analyze and visualize the distribution and the empirical cumulative di...

View code
Statistical
Confirmatory Factor Analysis with PROC CALIS

Example of confirmatory factor analysis using PROC CALIS on cognitive abilities data. The script defines and tests tw...

View code
Statistical
Example 25 for PROC CALIS - Latent Growth Curve Model

This SAS script uses the CALIS procedure to fit latent growth curve models, demonstrating longitudinal data analysis.

View code
Statistical
Example of Confirmatory Factor Analysis with PROC CALIS

This script performs a confirmatory factor analysis using the CALIS procedure to model the relationship between obser...

View code
Statistical
Categorical Data Analysis with PROC CATMOD

This SAS script performs a logistic regression analysis on categorical data from a detergent preference study using t...

View code
Statistical
Example Documentation 1 for PROC BCHOICE

This SAS script demonstrates the use of PROC BCHOICE to analyze discrete choice data, exploring alternative-specific ...

View code
Statistical
Covariance Structure Analysis with PROC CALIS

This script illustrates the use of the CALIS procedure to perform a direct covariance structure analysis on a COV typ...

View code
Statistical
Linear Regression Analysis and Visualization

This script performs two distinct linear regression analyses. The first examines the relationship between alcohol con...

View code
Statistical
Nonlinear Regression for Patient Prognosis

This script performs a nonlinear regression to model the relationship between the number of hospitalization days and ...

View code
Statistical
Descriptive analysis of categorical variables

This SAS script performs a descriptive analysis of numerical and categorical variables using PROC PRINT, PROC SQL, an...

View code
Statistical
Calculating the Kappa Coefficient for Movie Ratings

This SAS script calculates and compares the Kappa concordance coefficient for movie rating data using PROC FREQ and a...

View code
Statistical
GEE Analysis of Ordinal Shoulder Pain Data

This SAS script analyzes data from a Shoulder Tip Pain study using GEE (Generalized Estimating Equations) models for ...

View code
Statistical
Homogeneity Test for Aggregated Trinomial Results

This SAS script simulates aggregated (clustered) trinomial data for two products, then applies statistical procedures...

View code
Statistical
Pain Index Calculation

SAS macro calculating the Pain Index based on the distribution of returns.

View code
Statistical
Fitting Polynomial Models with PROC ORTHOREG and GLM

This script illustrates fitting polynomial models on generated data, using PROC ORTHOREG and GLM to compare the results.

View code
Statistical
Analysis of an Unbalanced Two-Factor Design

This SAS script performs an unbalanced two-factor analysis of variance (ANOVA) on internally created data, using the ...

View code
Statistical
ODS Documentation Example 3

This SAS script illustrates the use of the Output Delivery System (ODS) for documentation and visualization, performi...

View code
Statistical
Insurance Claims

This SAS script performs a Poisson regression to model insurance claims based on car type and age. It uses ODS to cap...

View code
Statistical
Documentation Example 5 for ODS

SAS example illustrating the capture of statistics (Chi-Square) into an output table via ODS OUTPUT.

View code
Statistical
Regression Analysis on Class and Population Data

This SAS script performs regression analyses on the internal 'sashelp.class' dataset and on a population dataset crea...

View code
Statistical
Documentation Example 1 for PROC NPAR1WAY

This SAS script demonstrates the use of PROC NPAR1WAY to perform non-parametric analyses on arthritis data, including...

View code
Statistical
PROC NPAR1WAY Example: Exact Wilcoxon Test

Example script from SAS/STAT documentation illustrating the use of PROC NPAR1WAY to perform a Wilcoxon test with exac...

View code
Statistical
Calculation of statistical functions with DATA step

This SAS script calculates and displays cumulative distribution function (CDF) values and the inverse quantile functi...

View code
Statistical
Documentation Example 4 for PROC NLMIXED

This SAS script uses PROC NLMIXED to model count data with a Poisson-Normal model.

View code
Statistical
Example 6 of documentation for PROC NLMIXED

This SAS script is a documentation example for PROC NLMIXED, simulating a nested random effects linear model.

View code
Statistical
PROC NLMIXED Getting Started Example 2

Getting started example for PROC NLMIXED, logistic-normal modeling of binomial data from a multicenter clinical trial.

View code
Statistical
Example 4 for PROC NLIN: Influence of Parameterization on Curvature

This script illustrates how different parameterizations of a nonlinear model affect the curvature and statistical pro...

View code
Statistical
Documentation Example 6 for PROC NLIN - ODS Graphics and Diagnostics

This SAS script illustrates the use of PROC NLIN for nonlinear regression analysis, generating ODS graphics and detai...

View code
Statistical
PROC NLIN Example with Parameter Profiling and Bootstrap

This script illustrates the use of the NLIN procedure to perform non-linear regression, with advanced features for pa...

View code
Statistical
PROC NLIN Example: Parameter Estimation for a Nonlinear Model

This SAS script uses PROC NLIN to estimate the parameters of nonlinear models, including an enzymatic reaction model,...

View code
Statistical
Probit-Normal Model with PROC NLMIXED for Binomial Data

This SAS script is an example of using the NLMIXED procedure to fit a probit-normal model to binomial data, illustrat...

View code
Statistical
Example 3 PROC NLMIXED Documentation: Probit-Normal Model

Fitting a Probit-Normal model for ordinal data using PROC NLMIXED.

View code
Statistical
Analysis of Calcium Variability in Turnip Leaves

This SAS script analyzes the variability of calcium concentration in turnip leaves using the NESTED procedure, accord...

View code
Statistical
Automobile Model Reliability

This SAS script analyzes the reliability of different automobile models using the NESTED procedure.

View code
Statistical
Mean_Abs_Deviation Macro

SAS macro to calculate the Mean Absolute Deviation from a financial returns dataset.

View code
Statistical
PROC LOESS Introduction Example: Melanoma Incidences

Comprehensive example illustrating the use of the LOESS procedure to analyze time series data (melanoma incidences) w...

View code
Statistical
Example 5 PROC LOGISTIC - Stratified Sampling

Illustration of the PEVENT= option to process data from stratified sampling (e.g., case-control) and correct prevalen...

View code
Statistical
Example 1 for the EFFECTPLOT Statement

Example of response surface analysis (Saddle Surface) using PROC ORTHOREG and the EFFECTPLOT statement for visualizat...

View code
Statistical
Example 6 for PROC GLM - Romano-British Pottery

This SAS script performs a multivariate analysis of variance (MANOVA) on chemical composition data of Romano-British ...

View code
Statistical
Example 9 for PROC GLM: Doubly Multivariate Repeated Measures Analysis

Analysis of a doubly multivariate repeated measures experimental design using PROC GLM.

View code
Statistical
Example 3 PROC HPFMM Documentation: Mixed Poisson Regression

Example of using PROC HPFMM to fit mixed Poisson regression models and analyze the impact of outliers.

View code
Statistical
Example 3 PROC FMM: Mixed Poisson Regression

Example of using the FMM procedure to fit Poisson regression and Poisson mixture models.

View code
Statistical
Correspondence Analysis: US Population 1920-1970

Example of simple correspondence analysis on US population data by region between 1920 and 1970.

View code
Statistical
CUSUM Macro - Recursive Residuals Analysis

SAS/IML routine calculating recursive residuals and their cumulative sums (CUSUM) to detect changes in regression par...

View code
Statistical
Data Simulation and Regression Analysis

This script generates a simulated dataset containing simple linear relationships, then performs several linear regres...

View code
Statistical
Chi-Square Statistical Analysis (Macro)

SAS macro to run a Chi-square test and export frequencies and probability of difference between groups.

View code
Statistical
Example 3 Details for PROC BOXPLOT

Example of using PROC BOXPLOT illustrating the management of extreme value display (clipping).

View code
Statistical
Example 8 of documentation for PROC CALIS

Illustration of estimating measurement error models with PROC CALIS compared to standard linear regression.

View code
Statistical
Factor Analysis with COSAN Model and Constraints (PROC CALIS)

Example of factor analysis using the generalized covariance structure (COSAN) model with constraints on parameters.

View code
Statistical
Factor analysis with ordinal constraints via PROC CALIS

Example of using the CALIS procedure to model a factor analysis with inequality (linear) constraints on the parameters.

View code
Statistical
Choice Model with Nested Logit - PROC BCHOICE Example

Example of using the BCHOICE procedure to fit and compare a nested logit model and a standard logit model on transpor...

View code
Statistical
Example 5 for PROC ANOVA

This SAS script performs an analysis of variance for a strip-split plot design to study the effect of soil, fertilize...

View code
Statistical
BART Procedure: Storage and Scoring

This documentation explains how to use the BART (Bayesian Additive Regression Trees) procedure to store a trained mod...

View code
Statistical
Probit Model for Binary Data with PROC BART

Demonstrates the use of the BART procedure to fit a Probit model on binary data, using an email dataset to classify s...

View code
Statistical
Analysis of Nonlinear Mixed Models (NLMIXED) for Binomial Data

This SAS script performs a statistical analysis of binary data using nonlinear mixed models (NLMIXED). It explores tw...

View code
Statistical
Alcohol-Malformation Relationship Analysis

Script analyzing the relationship between alcohol consumption and malformations through internal data creation and a ...

View code
Statistical
Variable Cardinality Analysis: Specific Levels

This script uses the CARDINALITY procedure to analyze the distribution of levels for a numeric or character variable,...

View code
Statistical
Force a Specific Order on a Variable (PROC CARDINALITY)

This SAS script illustrates how to use the CARDINALITY procedure in SAS Viya 4 to analyze variable cardinality and, s...

View code
Statistical
Descriptive Analysis and Normality Tests on Baseball Data

Descriptive statistical analysis script using the UNIVARIATE procedure to examine the distributions of nRuns and nHit...

View code
Statistical
Paired T-Test on CAFFIENE data

Execution of a T-test for paired samples to compare baseline and caffeine measurements.

View code
Statistical
Cutpoint Binning

The BINNING procedure with the CUTPTS method allows grouping continuous values of one or more variables into discrete...

View code
Statistical
Beyond PROC PRINT: How to Audit Data Quality and Spot Inconsistencies in SAS

This SAS script demonstrates common data exploration and validation techniques using base SAS procedures (PRINT, MEAN...

View code
Statistical
Exam Score Correlation Analysis

Creation of an exam response dataset, calculation of total score, and analysis of correlation between questions and t...

View code
Statistical
Dose-Response Linear Regression Analysis

Statistical analysis exploring the relationship between drug dosage and blood pressure.

View code
Statistical
Creating Frequency Charts with PROC FREQ

This program uses the PROC FREQ procedure to generate different types of frequency charts (bar charts) for univariate...

View code
Statistical
Descriptive Analysis of Numerical Variables

Descriptive analysis of a numerical variable (`lskew`) using PROC UNIVARIATE, including the creation of an internal d...

View code
Statistical
Bucket Binning and Weight of Evidence Calculation

This feature of the BINNING procedure allows grouping continuous or categorical variables into categories (bins) and ...

View code
Statistical
CARDINALITY Procedure: Variable with User-Defined Format

This example illustrates how the SAS Viya CARDINALITY procedure handles variables with user-defined formats. It demon...

View code
Statistical
Adjustment of Raw p-values with PROC MULTTEST

This SAS script illustrates the use of the MULTTEST procedure to adjust a set of raw p-values using the Holm, Hochber...

View code
Statistical
Peto's Mortality and Prevalence Test with PROC MULTTEST

Example illustrating the use of the MULTTEST procedure to perform a Peto test (mortality-prevalence) with permutation...

View code
Statistical
Example 1 for PROC MULTTEST

This script performs a Cochran-Armitage trend test on tumor data using a permutation resampling method to adjust p-va...

View code
Statistical
Documentation Example for PROC MODECLUS (modecex5)

This SAS script demonstrates the use of PROC MODECLUS for cluster analysis on unidimensional data, exploring the impa...

View code
Statistical
MODECLUS Analysis with JOIN Option

This SAS script demonstrates the use of PROC MODECLUS for cluster analysis on a synthetic dataset, including a visual...

View code
Statistical
Documentation Example 2 for PROC MODECLUS

Cluster analysis on 10 American cities based on flight distances using PROC MODECLUS.

View code
Statistical
mlmsumry Macro for Linear Models Analysis (GLM)

SAS macro facilitating the extraction and formatting of multivariate and univariate test statistics from the GLM proc...

View code
Statistical
Getting Started Example for PROC MIXED

This script is a simple example illustrating the use of PROC MIXED for mixed linear models analysis, using internal d...

View code
Statistical
Documentation Example 9 for PROC MIXED: Examination of Test Components

This script illustrates the use of the LCOMPONENTS option in the MIXED procedure to examine hypothesis tests (L matri...

View code
Statistical
Influence Analysis in a Heterogeneous Variance Model (PROC MIXED)

Example of using the MIXED procedure to fit a one-factor classification model with heterogeneous variances and perfor...

View code
Statistical
PROC MIXED Example: Known G and R Matrices

Example of genetic analysis with PROC MIXED using known G and R covariance matrices on artificial data.

View code
Statistical
Likelihood Surface Plot with PROC MIXED

Example illustrating how to generate and visualize a likelihood surface from a linear mixed model.

View code
Statistical
Isotonic contrasts with PROC MIXED

This SAS script demonstrates the use of PROC MIXED for the analysis of isotonic contrasts on ordered mean values, usi...

View code
Statistical
Example 17 for PROC MI: Multiple Imputation with MNAR adjustment

Demonstration of multiple imputation using the MNAR statement in PROC MI to adjust imputed values based on a monotoni...

View code
Statistical
Example 15 of documentation for PROC MI

This SAS script demonstrates the use of the PROC MI procedure for multiple imputation of missing data, specifically u...

View code
Statistical
Example 12 for PROC MIANALYZE: MNAR Sensitivity Analysis

This script illustrates a sensitivity analysis using the MNAR (Missing Not At Random) statement in the MI procedure, ...

View code
Statistical
Descriptive Statistics Macro (Means/Median)

SAS macro calculating and formatting descriptive statistics (mean, standard deviation, median, IQR) for continuous va...

View code
Statistical
Analysis of Flying Mileages Between Ten U.S. Cities with PROC MDS

Introductory example to the MDS (Multidimensional Scaling) procedure using mileage data between cities.

View code
Statistical
Example of using the REOBSINFO option in PROC MCMC

This SAS script illustrates the use of the MCMC procedure with the REOBSINFO option. It generates a simple input data...

View code
Statistical
Example of Multivariate Distribution Usage

This script generates multivariate normal data using PROC IML, then fits a Bayesian multivariate normal model using P...

View code
Statistical
Regenerating Diagnostic Plots

This script performs a Bayesian MCMC analysis on the `sashelp.class` dataset and then generates diagnostic plots for ...

View code
Statistical
Sans titre

This SAS script implements a simple Dynamic Linear Model (DLM) using the MCMC (Markov Chain Monte Carlo) procedure fo...

View code
Statistical
Introduction to PROC MCMC Example

This script illustrates an introductory example of using the PROC MCMC procedure for Bayesian regression analysis, mo...

View code
Statistical
PROC MCMC Getting Started Example 2: Behrens-Fisher Problem

Example illustrating the use of the MCMC procedure to solve the Behrens-Fisher problem (comparison of means of two no...

View code
Statistical
Random Effects Logistic Regression Model

This SAS script uses the MCMC procedure to fit a Bayesian logistic regression model with random effects, demonstratin...

View code
Statistical
Create Design Matrix for Bayesian Analysis

This SAS script prepares categorical data for Bayesian analysis by creating a design matrix. It uses internal data to...

View code
Statistical
Caterpillar Plot with PROC MCMC

This SAS/STAT example script illustrates the use of the MCMC procedure to fit a Bayesian logistic model with random e...

View code
Statistical
Chi-Square Test on Survey Data

This SAS script performs a frequency analysis and a Chi-square test on survey data, using custom formats to group var...

View code
Statistical
Test for a Difference Between Proportions (Chi-Square)

This SAS script demonstrates how to test for a significant difference between proportions using the FREQ procedure an...

View code
Statistical
Analysis of the mean difference between two groups

This SAS script simulates a population, draws a random sample from it, and prepares statistical analysis to test the ...

View code
Statistical
Mean Difference Test (T-Test) on Simulated Data

Generation of a random population and performance of a T-test to compare average heights between men and women.

View code
Statistical
Calculation of 95% Confidence Intervals

This script generates a population of 10,000 participants, then draws two random samples of different sizes (10 and 1...

View code
Statistical
Calculation of 95% Confidence Intervals and Sampling Simulation

Educational script demonstrating the calculation of confidence intervals on a simulated population and the effect of ...

View code
Statistical
Survival of Men with Angina Pectoris

This SAS script performs a survival analysis using the life table method to study the survival of men with angina pec...

View code
Statistical
Documentation Example 2 for PROC LIFETEST

This script illustrates the advanced use of the LIFETEST procedure for survival analysis, including managing the disp...

View code
Statistical
Bayesian Survival Analysis with PROC LIFEREG (Example 2)

Fan reliability analysis using a log-normal distribution and Bayesian estimation to predict the probability of failure.

View code
Statistical
Starter Example 1 for PROC LIFEREG

This SAS script is an introductory example of using PROC LIFEREG for survival data analysis. It creates an internal d...

View code
Statistical
Example 6 for PROC LIFEREG

Survival analysis using PROC LIFEREG with a lognormal model and generation of probability plots.

View code
Statistical
Example 5 for PROC LIFEREG

This SAS script illustrates the use of PROC LIFEREG for survival data analysis, including probability plotting for a ...

View code
Statistical
Natural Recovery Time - PROC LIFEREG Example

Survival analysis on natural recovery time data using the Weibull distribution with interval censoring.

View code
Statistical
Example 3 for PROC LIFEREG

This script illustrates the use of the LIFEREG procedure for survival data analysis, showing how to specify different...

View code
Statistical
Tobit Model Example with PROC LIFEREG

This SAS script illustrates the use of the LIFEREG procedure to fit a regression model on censored data (Tobit model)...

View code
Statistical
Basic Statistical Analysis with PROC MEANS

This SAS script demonstrates the creation of a dataset and the use of PRINT, SORT, and MEANS procedures for basic des...

View code
Statistical
Logistic Regression Analysis with Data Transformation

This SAS script performs a series of logistic regression analyses on an internally generated dataset, following a spe...

View code
Statistical
Medical Data Frequency Analysis

This SAS script reads medical data provided inline, with multiple observations per line, to create a 'medicine' datas...

View code
Statistical
Example Documentation for PROC LATTICE

This SAS script prepares an internal dataset for a statistical analysis of a lattice design, then executes PROC LATTI...

View code
Statistical
Getting Started Example for PROC KDE

This SAS script illustrates the use of the PROC KDE procedure for bivariate kernel density estimation, by generating ...

View code
Statistical
Power Analysis and Monte Carlo Simulation for Two-Means Test

This SAS script demonstrates the calculation of statistical power for a two-means comparison test, both theoretically...

View code
Statistical
Example of Introduction to SAS Discriminant Procedures

This SAS script generates a random dataset with two distinct groups, then performs a canonical discriminant analysis ...

View code
Statistical
Data standardization and temperature conversions with PROC IML

This SAS script uses PROC IML to perform data standardization of a SASHELP dataset and temperature conversions (Celsi...

View code
Statistical
Example Documentation for PROC INBREED

This script illustrates the use of PROC INBREED to calculate inbreeding and covariance coefficients in non-overlappin...

View code
Statistical
Example 1 for PROC ICPHREG

This script is an introductory example to the ICPHREG procedure, illustrating interval-censored survival data analysi...

View code
Statistical
Interval-Censored Survival Analysis with PROC ICLIFETEST

This SAS script illustrates the use of the ICLIFETEST procedure to perform non-parametric survival analysis on interv...

View code
Statistical
Example 4 for PROC ICLIFETEST

Analysis of interval-censored survival data comparing two treatments (RT and RCT) using imputed scores and a permutat...

View code
Statistical
Introduction Example for PROC ICLIFETEST (ICLFTGS1)

This script is the first introductory example for the ICLIFETEST procedure (Interval Censored Life Test). It analyzes...

View code
Statistical
Convergence Status Example with PROC MIXED

This SAS script illustrates how to monitor and capture the convergence status of iterative statistical models using t...

View code
Statistical
Unbalanced Variance Analysis with EFFECTPLOT (ICOMEP2)

Example of unbalanced two-factor variance analysis using PROC GENMOD and the EFFECTPLOT statement for visualization.

View code
Statistical
Example Documentation for PROC ICPHREG

This script is an example of using the ICPHREG procedure to fit a proportional hazards regression model on interval-c...

View code
Statistical
Interval-censored survival analysis using PROC ICPHREG

Example of fitting a proportional hazards model to interval-censored data using cubic splines for the baseline hazard...

View code
Statistical
Example Documentation 3 for PROC ICPHREG

Example of fitting a proportional hazards model with interval censoring using cubic splines for the baseline hazard.

View code
Statistical
Analysis with PROC HPSPLIT

This script illustrates the use of PROC HPSPLIT for statistical modeling on baseball data and displaying the results.

View code
Statistical
Getting Started Example for PROC HPSPLIT - Wine Classification

Example script illustrating the creation of classification trees to predict wine cultivars.

View code
Statistical
Example Documentation 1 for SEM Introduction

This SAS script demonstrates the use of the CALIS procedure for Structural Equation Modeling (SEM) analysis, focusing...

View code
Statistical
Example 1 for PROC ICLIFETEST (Interval-Censored Data)

This SAS script illustrates the use of the ICLIFETEST procedure for the analysis of duration data with interval censo...

View code
Statistical
Example 2 PROC ICLIFETEST - Cosmetic Data

Example of using the ICLIFETEST procedure for the analysis of interval-censored survival data, comparing two treatments.

View code
Statistical
Example Detail Section for PROC HPQUANTSELECT

This SAS script demonstrates the use of PROC HPQUANTSELECT with examples of class variables and model selection.

View code
Statistical
Example 1 for PROC HPQUANTSELECT

This SAS script simulates data and uses the PROC HPQUANTSELECT procedure to perform quantile regression model selecti...

View code
Statistical
Example of Details Section for PROC HPREG

This SAS script generates a synthetic dataset and then uses the HPREG procedure to perform high-performance regressio...

View code
Statistical
Regression Analysis with PROC HPREG on Simulated Data

This script simulates a dataset and applies the HPREG procedure for regression analysis with ForwardSwap model select...

View code
Statistical
Decision Tree Model with PROC HPSPLIT

This script uses the PROC HPSPLIT procedure to build and evaluate decision tree models using cross-validation and cos...

View code
Statistical
Getting Started Example for PROC HPNLMOD

Estimating Parameters Using Maximum Likelihood

View code
Statistical
Comparison of methods for PROC HPPLS

This SAS script compares the results of three multivariate regression analysis methods (RRR, PCR, PLS) using the HPPL...

View code
Statistical
Example 4 PROC HPGENSELECT: LASSO Model Selection

This script illustrates the use of the HPGENSELECT procedure to perform LASSO model selection on simulated data.

View code
Statistical
Getting Started Example for PROC HPLMIXED

This SAS script generates a synthetic dataset named 'SchoolSample' and then applies a generalized mixed models analys...

View code
Statistical
Example 2 for PROC HPMIXED

This SAS script compares the use and results of HPMIXED and MIXED procedures for mixed linear model analysis.

View code
Statistical
Example 3 PROC HPMIXED: Joint use with PROC GLIMMIX

Demonstration of using PROC HPMIXED to estimate parameters on a large simulated dataset, then transferring these esti...

View code
Statistical
HPNLNGS1 - Startup example for PROC HPNLMOD

Example of using the HPNLMOD procedure to estimate parameters of a nonlinear regression model on enzymatic reaction d...

View code
Statistical
PROC HPFMM Getting Started Example: Binomial Mixture Distributions

Fitting finite mixture models to binomial data (yeast cells) with PROC HPFMM.

View code
Statistical
Non-Parametric Tweedie Regression with PROC GAMPL

Example of fitting a non-parametric Tweedie regression model on simulated data.

View code
Statistical
Example of PROC GAMPL usage for vote study

This script uses the GAMPL procedure to model the proportion of votes in US counties in 1980 based on various socio-e...

View code
Statistical
Automobile Data Analysis and Visualization

This SAS script creates an internal dataset, performs a frequency analysis, and generates graphs to visualize the rel...

View code
Statistical
Example 7 for PROC GLMSELECT

This SAS example simulates data and uses PROC GLMSELECT for model selection with the LASSO method, including differen...

View code
Statistical
Examples of details for PROC GLMPOWER

This SAS script demonstrates the use of the GLMPOWER procedure to perform power analysis, based on internal data. It ...

View code
Statistical
Example Documentation 3 for PROC GLMPOWER

Power analysis and sample size calculation for a repeated measures ANOVA.

View code
Statistical
Power calculation example for a two-way ANOVA

This SAS script illustrates how to use the GLMPOWER procedure to perform power and sample size analysis for a two-way...

View code
Statistical
Example 2 for PROC GLMPOWER - Power Analysis

Calculates statistical power for a General Linear Model (GLM) using PROC GLMPOWER. The example includes contrasts and...

View code
Statistical
PROC GLIMMIX Example 7

This SAS script uses PROC GLIMMIX to analyze the magnetic force of ferrite cores at different temperatures, applying ...

View code
Statistical
Mixed Model Analysis (GLM and MIXED)

This SAS script performs a mixed model analysis of variance using GLM and MIXED procedures on an internally generated...

View code
Statistical
Quadratic and Linear Regression with PROC GLM

This SAS script illustrates the use of PROC GLM for fitting quadratic and linear regression models, as well as genera...

View code
Statistical
Analysis of Nitrogen Content in Clover Plants

This SAS script analyzes the nitrogen content of red clover plants using Generalized Linear Models (GLMMOD) and regre...

View code
Statistical
Example 1 for PROC GLMMOD

This SAS script demonstrates the use of the GLMMOD procedure for generalized linear model analysis, by creating an in...

View code
Statistical
PROC GLMMOD and PROC REG for Forward Stepwise Selection

This SAS script uses PROC GLMMOD to generate a design matrix from an internal dataset, then PROC REG to perform forwa...

View code
Statistical
GLM Analysis for Unbalanced ANOVA

This script illustrates the use of PROC GLM for an unbalanced ANOVA with a 2x2 factorial design and the generation of...

View code
Statistical
PROC GLMSELECT Example with Model Selection

This SAS script demonstrates the use of the GLMSELECT procedure for generalized linear model selection with different...

View code
Statistical
Detailed Example 4 for PROC GLM

This script illustrates the use of the GLM (General Linear Model) procedure for the analysis of an unbalanced two-fac...

View code
Statistical
Detailed Example 5 for PROC GLM (Simple Effects)

This SAS script illustrates the use of PROC GLM for analyzing simple effects in a general linear model, using data cr...

View code
Statistical
Analysis of Balanced Randomized Complete Block Data

This SAS script performs an analysis of variance (ANOVA) to study the effect of soil type and block on snapdragon ste...

View code
Statistical
Example 4 for PROC GLM - Analysis of Covariance

This script performs a covariance analysis to evaluate the effect of a drug (Drug) on a treatment (PostTreatment) by ...

View code
Statistical
Three-factor ANOVA with PROC GLM (GLMEX5)

Example from the SAS sample library (GLMEX5) demonstrating a three-factor analysis of variance (ANOVA).

View code
Statistical
Example 7 for PROC GLM - Repeated Measures Analysis of Variance

Example of repeated measures analysis of variance on canine physiological data.

View code
Statistical
Details for Example 3 for PROC GLM (Absorption in ANOVA)

Demonstration of using the ABSORB statement in PROC GLM for efficient statistical calculations, especially in the pre...

View code
Statistical
Detailed Example 2 for PROC GLM

This SAS script uses PROC GLM to perform an analysis of variance, with a focus on calculating effect size for F-tests...

View code
Statistical
Longitudinal Analysis and Mixed Model

This SAS script imports data from a longitudinal study, performs data cleaning, calculates descriptive means, visuali...

View code
Statistical
Baseball Statistics Analysis with CAS

This SAS Viya 4 script loads baseball data from the SASHELP library into a CAS table, then performs statistical analy...

View code
Statistical
Monte Carlo Permutation Test with PROC IML

Performing a permutation test (Monte Carlo) to compare means between two groups using PROC IML for data generation.

View code
Statistical
Permutation (Randomization) Test for Mean Comparison

Execution of a permutation test to compare age means between two groups.

View code
Statistical
Power analysis for two means

Performs a power analysis for a two-independent-means comparison test, calculating the required total sample size and...

View code
Statistical
Power analysis for comparing two means

This SAS script uses the PROC POWER procedure to perform a power analysis to determine the necessary sample size for ...

View code
Statistical
Power Analysis for Two Means

This SAS script performs a power analysis for a two-mean comparison test, allowing the determination of statistical p...

View code
Statistical
Monte Carlo Permutation Test with PROC IML and PROC TTEST

This script implements a permutation test (randomization test) to compare the means of two groups. It generates an em...

View code
Statistical
T-Test Analysis on Tuition Fees

This SAS script performs a t-test to compare tuition fees between 'In' (internal) and 'Out' (external) students.

View code
Statistical
Univariate analysis of the difference between two measurements

This SAS script calculates the difference between two measurements ('after' and 'before') for a set of individuals an...

View code
Statistical
Permutation Test for Mean Comparison

This SAS script performs a permutation test to evaluate the difference in means between two groups (traumatized vs. n...

View code
Statistical
Example 1 for PROC GENMOD

This SAS script is an example of using PROC GENMOD to fit a generalized linear model, specifically a logistic regress...

View code
Statistical
Example 2 for PROC GENMOD

This SAS script demonstrates the use of PROC GENMOD to fit a generalized linear model with a normal distribution and ...

View code
Statistical
Example 4 for PROC GENMOD

This SAS script demonstrates the use of the GENMOD procedure to fit a generalized linear model with an ordinal multin...

View code
Statistical
PROC GENMOD Introduction Example

This SAS script creates an 'insure' dataset and applies the GENMOD procedure to fit a generalized linear Poisson mode...

View code
Statistical
Friedman Chi-Square Test with PROC FREQ

This SAS script performs the Friedman Chi-Square test to analyze skin responses of subjects under hypnosis based on d...

View code
Statistical
Example introduction for PROC FREQ

This SAS script demonstrates the use of PROC FREQ to generate frequency tables, cross-tabulation tables, and various ...

View code
Statistical
PROC FREQ Starter Example 2

Categorical data analysis and calculation of Kappa statistics to evaluate agreement between two dermatologists on ski...

View code
Statistical
Chi-Square Goodness-of-Fit Test (SAS FREQEX3 Example)

This script illustrates the use of the FREQ procedure to perform a Chi-square goodness-of-fit test on categorical dat...

View code
Statistical
Documentation Example 4 for PROC FREQ

Example of using PROC FREQ to calculate binomial proportions and perform equivalence tests.

View code
Statistical
Documentation Example 5 for PROC FREQ

This SAS script analyzes a 2x2 contingency table using PROC FREQ for a case-control study. It defines custom formats,...

View code
Statistical
Example 6 PROC FREQ: Chi-Square Statistics Output

Example of using the FREQ procedure to perform Chi-Square tests and export the resulting statistics to a SAS dataset.

View code
Statistical
PROC FREQ Example 10 - Cochran's Q Test

This SAS script illustrates the use of PROC FREQ to perform categorical data analyses, including Cochran's Q test and...

View code
Statistical
Example documentation for PROC FREQ

This SAS script creates a dataset on the eye and hair color of European children, then uses the FREQ procedure to gen...

View code
Statistical
Documentation example 2 for PROC FREQ

This SAS script generates frequency tables and dot plots for eye and hair colors, as well as geographic region, using...

View code
Statistical
Example of PROC FMM usage for binomial distribution mixtures

This script illustrates how to use the FMM procedure to fit a two-component binomial mixture model to count data (Stu...

View code
Statistical
Factor Analysis Example (PROC FACTOR)

This SAS script performs a series of factor analyses using the maximum likelihood method on socioeconomic data, testi...

View code
Statistical
Example Documentation 5 for PROC FACTOR

This example illustrates how to use standard errors and confidence intervals to understand the factor loading model u...

View code
Statistical
Documentation Example 2 for PROC FACTOR

Example of principal factor analysis using the FACTOR procedure on socio-economic data.

View code
Statistical
Time Series Transformation with PROC TSMODEL and TSL

This script illustrates the use of the CAS PROC TSMODEL procedure and the TSL (Time Series Language) scripting langua...

View code
Statistical
Non-parametric analysis of candidate incomes

This SAS script imports candidate income data from an external CSV file, performs exploratory analysis via graphs (bo...

View code
Statistical
Discriminant Analysis of Fisher's (1936) Iris Data

This script performs a quadratic discriminant analysis on Fisher's Iris data, then displays the resulting statistics.

View code
Statistical
Getting Started Example for PROC DISCRIM

Basic demonstration of discriminant analysis using the fish measurement table.

View code
Statistical
Diet Data Frequency Analysis

This SAS script creates an internal dataset named 'diet' and then performs a cross-frequency analysis between the 'vi...

View code
Statistical
Analysis of PhDs Awarded

This SAS script performs a correspondence analysis on the data of the number of PhDs awarded in different scientific ...

View code
Statistical
Correlation Coefficient Demonstration and Animated GIF

SAS macro simulating data with a specific correlation coefficient and producing a graphical visualization.

View code
Statistical
CORRESP Macro - Correspondence Analysis

SAS macro for performing simple and multiple correspondence analyses (MCA) with extended graphical options.

View code
Statistical
Example of Cluster Analysis with PROC CLUSTER

This script illustrates the use of the CLUSTER procedure to perform a cluster analysis on flight distances between 10...

View code
Statistical
Example 7 for PROC CATMOD: Repeated Measures Analysis

Example of visual symmetry analysis (right eye vs. left eye) using PROC CATMOD to test marginal homogeneity on repeat...

View code
Statistical
Startup Example for PROC CATMOD - WLS Analysis of Mean Response

This SAS script demonstrates the use of PROC CATMOD for Weighted Least Squares (WLS) analysis of the mean response, a...

View code
Statistical
CATGS2 - Getting Started Example for PROC CATMOD

Example of using the CATMOD procedure to fit a generalized logits model to school survey data.

View code
Statistical
Example Documentation for PROC CANDISC (Fisher's IRIS Data)

This SAS script performs a canonical discriminant analysis on Fisher's IRIS data, then visualizes the results of the ...

View code
Statistical
Example initiation for PROC CANDISC

This script performs a canonical discriminant analysis on fish measurement data (SASHELP.FISH) and generates a plot o...

View code
Statistical
Logistic Regression with PROC CATMOD (Example 3)

Standard example from the SAS/STAT library illustrating maximum likelihood logistic regression on experimental ingot ...

View code
Statistical
Example 4 for PROC CATMOD: Log-Linear Model

Survival analysis of plant cuttings using a log-linear model with PROC CATMOD, based on Bartlett's data.

View code
Statistical
PROC CALIS Documentation Example

This script illustrates the use of PROC CALIS for structural equation modeling analysis, particularly the COVPATTERN ...

View code
Statistical
Path Analysis and Regression with CALIS and REG

This SAS script illustrates the use of CALIS and REG procedures for data analysis, with internal data creation via a ...

View code
Statistical
Documentation Example 15 for PROC CALIS - Factor Analysis with Missing Data

Example of confirmatory factor analysis using PROC CALIS with missing data handling.

View code
Statistical
PROC CALIS Documentation Example 16

This SAS script demonstrates the use of the CALIS procedure for factor analysis, particularly with the handling of mi...

View code
Statistical
Canonical Correlation Analysis (CANCOEX1)

This SAS script performs a canonical correlation analysis on physiological measurements and physical exercise data. I...

View code
Statistical
Canonical Correlation Analysis with PROC CANCORR

This SAS script demonstrates the use of PROC CANCORR to perform a canonical correlation analysis between two sets of ...

View code
Statistical
Example Documentation 1 for PROC CAUSALGRAPH

Example of graphical causal models (DAG) analysis to identify causal effects.

View code
Statistical
Documentation Example 4 for PROC CAUSALGRAPH

This SAS script illustrates the use of PROC CAUSALGRAPH to define and analyze graphical causal models based on specif...

View code
Statistical
Example Documentation 6 for PROC CAUSALGRAPH

This SAS script demonstrates the use of the CAUSALGRAPH procedure to define, analyze, and identify causal effects in ...

View code
Statistical
Example 1 for PROC CAUSALGRAPH

Demonstration of the CAUSALGRAPH procedure to specify a causal graphical model and identify causal effects between va...

View code
Statistical
Covariance Matrix Equality Test with PROC CALIS

This SAS script uses the CALIS procedure to test the equality of covariance matrices between two groups, 'Expert' and...

View code
Statistical
Example of PROC CALIS for Covariance Estimation

This SAS script illustrates the use of PROC CALIS for covariance structure analysis, using internally created data.

View code
Statistical
Example documentation for PROC CALIS

This SAS script is an example of using the CALIS procedure for mean and covariance structure analysis on an internal ...

View code
Statistical
Example Documentation 3 for PROC CALIS

This SAS script demonstrates the use of PROC CALIS for analyzing non-correlation models on sales data.

View code
Statistical
Sphericity Test with PROC CALIS (Example 4)

SAS documentation example (CALEX105) illustrating the use of the CALIS procedure to test covariance models.

View code
Statistical
Conjoint Analysis of Chocolates (BCHOICE)

This SAS script performs a conjoint analysis of a set of chocolates using the BCHOICE procedure to fit a simple logit...

View code
Statistical
Example 8 PROC BGLIMM: Using Power Prior

Illustration of using the BGLIMM procedure to incorporate historical data via the 'Power Priors' method.

View code
Statistical
Analysis of Eye and Hair Color Frequency by Region

This SAS script creates a 'Color' dataset from embedded data (datalines) and then performs several frequency analyses...

View code
Statistical
Boxplot Example Grouped by Machine

Generation of a box plot to analyze diameters, grouped by sample number and machine.

View code
Statistical
Analysis of Variance for a Randomized Complete Block Design

This SAS script performs an Analysis of Variance (ANOVA) for a randomized complete block design with a factorial trea...

View code
Statistical
Example 2 for PROC ANOVA: Multiple Comparisons

Example of using PROC ANOVA to analyze the nitrogen content of red clover plants inoculated with different bacterial ...

View code
Statistical
Analysis of variance of a split-plot design

This SAS script illustrates the use of PROC ANOVA to analyze a split-plot design, based on Example 3 from the PROC AN...

View code
Statistical
ANOVAIN1

Introductory example for one-way analysis of variance (One-Way ANOVA) with PROC ANOVA, analyzing the nitrogen content...

View code
Statistical
Analysis of Variance: Randomized Complete Block Example

This SAS script performs an Analysis of Variance (ANOVA) for a randomized complete block design with a single factor,...

View code
Statistical
AHGstatfreqvert Macro: Frequency and Statistics Calculation

Macro to calculate vertical frequencies and other statistics on a given variable, with formatting options and missing...

View code
Statistical
AHGstatfreqvertby Stratified Frequency Macro

Macro calculating statistical frequencies for a given variable, stratified by a grouping variable (BY), with layout o...

View code
Statistical
Descriptive Statistics Calculation Macro AHGstatmeans

SAS macro calculating customizable descriptive statistics (n, mean, median, etc.) for a given variable with formattin...

View code
Statistical
Macro AHGstats_vertical - Calculation and Formatting of Statistics

SAS macro to calculate descriptive statistics on a variable, with formatting and transposition options.

View code
Statistical
Advanced Descriptive Analysis with PROC MEANS

Comprehensive demonstration of PROC MEANS procedure capabilities for descriptive analysis, including default statisti...

View code
Statistical
Student's t-test on carat data

Creation of a dataset and performing a Student's t-test.

View code
Statistical
Frequency Analysis with PROC FREQTAB and CAS

This SAS script uses the Cloud Analytic Services (CAS) engine to create a table from `sashelp.baseball` and perform a...

View code
Statistical
Binomial Probability Analysis

This SAS script calculates and presents the probabilities of non-missing events based on a binomial distribution, var...

View code
Statistical
AHGfreqCore Macro - Frequency Calculation and Transposition

Utility macro to calculate frequencies (PROC FREQ), format results, and optionally transpose the output.

View code
Statistical
Frequency Analysis of School-Money Associations

Creation of a `school` dataset from raw multi-observation data per line, followed by a frequency analysis of `money` ...

View code
Statistical
Frequency Analysis with Internal Data and CMH Statistics

This SAS script creates a 'cmh' dataset from embedded data and then performs a frequency analysis and cross-tabulatio...

View code
Statistical
Frequency Analysis with Multi-Line Data

This SAS script reads data organized in multi-observation per line format via DATALINES to create the 'medicine' data...

View code
Statistical
Adaptive Regression Analysis with Simulated Data

This SAS script simulates data according to a mixture model and then applies the ADAPTIVEREG procedure to perform ada...

View code
Statistical
Principal Component Analysis (ACECLUS) and Iris Data Clustering

Documentation example for the ACECLUS procedure, performing cluster analysis on Fisher's Iris data.

View code
Statistical
Assignment of experimental units and dataset operations

This SAS script demonstrates methods for assigning experimental units (subjects) to treatment groups in a balanced an...

View code
Statistical
Analysis of Weight Difference Before and After a Diet

This SAS script performs a paired t-test to evaluate the weight difference before and after a diet, based on data dir...

View code
Statistical
Zero-Inflated Poisson GLOMM Model

This SAS script generates data following a Zero-Inflated Poisson Generalized Linear Mixed Model (GLOMM), then estimat...

View code
Statistical
ZINB GLOMM Simulation and Analysis

Generation of simulated data for a zero-inflated negative binomial generalized linear mixed model and parameter estim...

View code
Statistical
Generation and Analysis of Simulated Clinical Data

The SAS script generates a simulated clinical dataset (`CLINICAL`) containing information on patients, visits, dates,...

View code
Statistical
Ratio Analysis for City Sizes with GLIMMIX and GENMOD

This SAS script performs a ratio analysis on city size data using GLIMMIX and GENMOD procedures to model count data w...

View code
Statistical
Analysis of Relative Risk and Rate Ratio in a Clinical Trial

This SAS script analyzes hypothetical data from a clinical trial to estimate the relative risk and rate ratio of adve...

View code
Statistical
Pump Reliability Analysis using Mixed Models

This SAS script analyzes the reliability of pumps in a pressurized water reactor nuclear power plant using generalize...

View code
Statistical
Ossification Data Analysis with PROC GENMOD

This script analyzes ossification study data using Generalized Estimating Equations (GEE) models with PROC GENMOD. It...

View code
Statistical
Simulation and classification of white blood cell (WBC) counts

Generation of simulated data for white blood cells and comparison of classification methods (Data step vs Format).

View code
Statistical
Basic statistical analysis of internal data

This SAS script reads numerical data from datalines, then performs a basic statistical analysis (number of observatio...

View code
Statistical
Goodness-of-Fit (GOF) Test for DataSet III

This SAS script performs Goodness-of-Fit tests and generates Q-Q plots to analyze residuals from a dataset by Haseman...

View code
Statistical
Basic Frequency Reports

This program generates frequency counts for each unique value in the columns of the SASHELP.CARS table.

View code
Statistical
Comparing PROC SUMMARY and PROC MEANS

This SAS script compares the PROC SUMMARY and PROC MEANS procedures, highlighting their main differences in terms of ...

View code
Statistical
Seed Germination Analysis (Williams 1982)

Statistical analysis of seed germination data (Crowder 1978) comparing logistic models with and without Williams' sca...

View code
Statistical
Analysis of Vertebral Fractures using a Poisson Model

This SAS script prepares internal data on vertebral fractures and performs a statistical analysis using a quasi-likel...

View code
Statistical
Toxoplasmosis Analysis - Efron Example

Statistical analysis of toxoplasmosis data using generalized linear mixed models (GLIMMIX) and generalized linear mod...

View code
Statistical
Survival Analysis - Laryngeal Cancer (Example 1.8)

This script analyzes the survival times of male patients with laryngeal cancer. It prepares the data, creates dummy v...

View code
Statistical
Random Assignment of Subjects to Groups

This SAS script demonstrates the use of a DO loop for the random assignment of subjects to treatment or control group...

View code
Statistical
Ille-et-Vilaine Esophageal Cancer Study (Tuyns et al., 1977)

This SAS script analyzes data from the Ille-et-Vilaine esophageal cancer study (Tuyns et al., 1977). It prepares raw ...

View code
Statistical
Descriptive Numerical Analysis of Height and Weight Variables

This SAS script performs a descriptive analysis of numerical variables (height, weight) from internally created data,...

View code
Statistical
Analysis of Electronic Failures with PROC GLIMMIX

Statistical modeling of the number of electronic equipment failures using the GLIMMIX procedure with different optimi...

View code
Statistical
Statistical Analysis and Correlation Calculation on SASHELP.CARS

This SAS script performs a series of statistical analyses on the `sashelp.cars` dataset, including data description, ...

View code
Statistical
Descriptive Analysis of BMI and Graphical Visualization

This SAS script performs a descriptive analysis of the Body Mass Index (BMI) by creating an internal dataset, then ge...

View code
Statistical
Variance analysis and regression on simulated cardiac data

Comparative statistical analysis using ANOVA (PROC GLM) and linear regression (PROC REG) on simulated biometric data.

View code
Statistical
Non-linear regression analysis with left-plateau model and visualization

This SAS script fits a 'left-plateau' type non-linear regression model to lizard mass and length data. It then visual...

View code
Statistical
Polynomial Regression Analysis on Cell Life Expectancy

Analysis of the life expectancy of energy cells based on charge rate and temperature using polynomial regression models.

View code
Statistical
Survival Analysis for Boron Neutron Capture Therapy

This SAS script performs a survival analysis to compare the survival curves of three groups (control, radiation, radi...

View code