New SAS Software for LCA With Covariates

May 4, 2020:

blank LCA diagram: a latent variable represented by an oval and four arrows pointing towards manifest variables represented by rectangles

PROC LCA is our free add-on to SAS statistical software for estimating latent class models. We are pleased to announce the release of the LCA Covariates 3-Step SAS macro, which supplements PROC LCA’s functionality. The macro estimates the association between covariates and latent class membership using the approach of Bolck, Croon, and Hagenaars (2004), as adapted by Vermunt (2010) and Vermunt and Magidson (2015). It is a “three-step” (noninclusive) approach, which is a flexible and robust alternative to the “one-step” (inclusive) approach implemented via the COVARIATES statement in PROC LCA.

Note: This does not mean that models using the COVARIATES statement are invalid. It does mean that covariates will not affect estimation of the measurement model; when assumptions of the “one-step” approach are met, results using the new macro will be very similar to those with the COVARIATES statement.

Read more or download the macro.

New R-Package for Optimizing Interventions

January 24, 2018:CRAN

Our latest software release will assist R users who are planning studies that follow the multiphase optimization strategy (MOST). The MOST: Multiphase Optimization Strategy R package combines the functionality of the RelativeCosts1 SAS macro for charting the relative costs of reduced factorial designs; the FactorialPowerPlan SAS macro for calculating the power, effect size, or sample size of a factorial experiment; and the Random Assignment Generator for factorial experiments web applet. The software is hosted on CRAN, the Comprehensive R Archive Network, rather than on our website in order to make it available to as many R users as possible.

Download the MOST CRAN package.

New Software for LCA with a Distal Outcome

June 16, 2017:

Our LCA distal outcome estimation software allows users to estimate the association between a latent class variable and a distal outcome in either Stata or SAS. Our previous LCA distal outcome releases have employed a model-based approach known as the LTB approach. As research on LCA with a distal outcome advanced, it became clear that a different method, one developed by Bolck, Croon and Hagenaars (2004), produces more accurate estimates in certain cases. We have implemented this method, known as the BCH approach, in a new SAS macro and Stata function. We recommend the new LCA_Distal_BCH SAS macro and LCA_Distal_BCH Stata function for estimating LCA with a distal outcome.

To facilitate methodological research, we have also repackaged the previous LCA_Distal SAS macro (v. 3.0.2) and the previous LCA_Distal Stata function as the LCA_Distal_LTB SAS macro and the LCA_Distal_LTB Stata function, respectively.

Open the SAS distal outcomes software page.

Open the Stata distal outcomes software page.

Sample Size Calculator for Micro-Randomized Trials

November 30, 2016:

Micro-randomized trials (MRTs) are a type of experiment for use in developing a mobile intervention. In order to understand MRTs, consider an interventionmrt that promotes physical activity among cardiac patients.

In this intervention an app displays messages on participants’ smartphones. These messages encourage participants to engage in activity. The application designers identified five times throughout the day when people are most likely to be available to exercise, and one goal of the study is to determine which prompts work best at which times and under what circumstances. At each of the five time points, the application randomly decides to prompt or not prompt each participant to become active; over the course of the intervention, each participant is randomized hundreds or thousands of times. This sequence of both within-participant and between-participant randomizations comprises the MRT.

The application also records outcomes. In this case, one outcome is whether or not the smartphone’s accelerometer detects physical activity by the participant in the hour following randomization. Another outcome is the participant’s overall level of physical activity. The application also records the participant’s context during each randomization (using GPS to determine the person’s location and the local weather). The resulting data is used by researchers to assess the effectiveness of the prompts and to build rules for when to prompt and not prompt participants to become active. In other MRTs, the randomization could apply to what type of intervention to provide, rather than whether or not to provide a prompt. MRTs are a key tool in the construction of just-in-time adaptive interventions, which are empirically validated, mobile-device based interventions.

A new web applet allows users to calculate the number of subjects needed for an MRT given the length of the study, the number of randomizations per day, and a few other criteria. The methodological foundation of the applet is explained in “Sample size calculations for micro-randomized trials in mHealth,” recently published in the journal Statistics in Medicine.

Open the applet.

Open the article. (Journal access required.)

New LCA Software: Bootstrap and Distal Outcomes

May 31, 2016:

We are pleased to release two new functions that augment the functionality of the LCA Stata plugin. The LCA Bootstrap Stata function allows users to perform the bootstrap likelihood ratio test in order to choose the number of classes for their latent class model. The LCA Distal Stata function allows users to estimate the association between a latent class variable and a binary distal outcome using a model-based approach. Both functions require the LCA Stata plugin version 1.2.1 or higher and Stata version 11 or higher. For SAS users, the LCA Distal SAS macro and LCA Bootstrap SAS macro have both been updated with small functional tweaks or bug fixes.

Download the Bootstrap function

Download the Distal function

New Applet for Random Assignment

December 2, 2015:

blank MOST flow chartWe are pleased to announce the release of a new web applet helpful when conducting factorial experiments and fractional factorial experiments. The applet produces a list of random numbers that can be used to assign subjects to experimental conditions. When the applet is used properly, subjects will be spread as evenly as possible across conditions. Factorial and fractional factorial experiments are useful for selecting the components to be included in an intervention when scientists are following the multiphase optimization strategy (MOST).

Open the applet

Major Revision of SAS TVEM Macro for Intensive Longitudinal Data

October 14, 2015:image of sample TVEM plot

The latest version of the TVEM (time-varying effect modeling) SAS macro (v. 3.1.0) offers several improvements over the previous version (v 2.1.1). Three macros from the previous suite have been consolidated into a single macro with simplified syntax for ease of use. Also, the new macro has the ability to model within-subject correlation using random effects or a robust sandwich variance estimator. Other improvements have been made to the onscreen output, the ability to generate output datasets, and the ability to generate plots in different ways.

TVEM allows researchers to answer new questions using intensive longitudinal data and mature panel studies, as well as answer questions about age-varying effects using less intensive data.

Traditional analytic methods assume that covariates have constant effects on a time-varying outcome. The TVEM SAS macro allows the effects of covariates to vary with time. The macro enables researchers to answer new research questions about how relationships change over time. The new version of the macro does not currently include accommodate zero-inflated Poisson (ZIP) outcomes. The previous version (2.1.1) of the %TVEM ZIP macro is still available.

Download the macro or read more.

Software Update: LCA Stata Plugin

September 3, 2015:

The Methodology Center is pleased to release the latest version (1.2.1) of the LCA Stata plugin for conducting latent class analysis (LCA). The latest version includes two small bug fixes and several changes to the users’ guide. As always, the software is available for download free of charge, though you need Stata to use it. For an overview of the functionality of the LCA Stata plugin, please visit the download page.

After a maintenance period this summer, all Methodology Center software is again available for download from the website. Please email with any questions or feedback.