12 Useful Macros

Introduction

Listing All or Part of a Data Set

Computing Differences between Successive Observations

Computing Differences between the First and Last Observations per Subject

Computing a Moving Average

Computing Cell Means and Counts

Counting the Number of Observations per Subject

Introduction

This chapter contains a collection of SAS macros that perform several of the longitudinal data tasks described in earlier chapters. This chapter is included primarily for readers who are already familiar with SAS macros. By “packaging” some of the programs described earlier in this book as macros, you can perform some of the common tasks associated with longitudinal data by calling the macro with the appropriate arguments. You may want ...

Get Longitudinal Data and SAS now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.