Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: New package -punaf- on SSC

From   Roger Newson <[email protected]>
To   "[email protected]" <[email protected]>
Subject   st: New package -punaf- on SSC
Date   Fri, 15 Oct 2010 15:30:40 +0100

Thanks as always to Kit Baum, a new package -punaf- is now downloadable from SSC. In Stata, use the -ssc- command to do this.

The -punaf- package is described as below on my website, and is planned as a natural Stata Version 11 successor to Tony Brady's Stata Version 6 -aflogit- package to calculate population attributable fractions (PAFs). The current version of -punaf-, however, only calculates PAFs for cohort and cross-sectional studies, which are easy if you use the the Stata 11 -margins- and -nlcom- commands. I am currently planning the next version of -punaf-, which I intend to be able to calculate the PAFs for case-control studies, which can be a bit more complicated, even if you use -margins- and -nlcom-. I would like to thank all at Statacorp for providing these 2 very useful commands.

Best wishes


Roger B Newson BSc MSc DPhil
Lecturer in Medical Statistics
Respiratory Epidemiology and Public Health Group
National Heart and Lung Institute
Imperial College London
Royal Brompton Campus
Room 33, Emmanuel Kaye Building
1B Manresa Road
London SW3 6LR
Tel: +44 (0)20 7352 8121 ext 3381
Fax: +44 (0)20 7351 8322
Email: [email protected]
Web page:
Departmental Web page:

Opinions expressed are those of the author, not of the institution.

package punaf from

      punaf: Population attributable fractions for cohort studies

      punaf calculates confidence intervals for population attributable
      fractions, and also for scenario means and their ratio, known as
      the population unattributable fraction.  punaf can be used after
      an estimation command whose predicted values are interpreted as
      conditional arithmetic means, such as logit, logistic, poisson,
      or glm.  It estimates the logs of two scenario means, the
      baseline scenario ("Scenario 0") and a fantasy scenario
      ("Scenario 1"), in which one or more exposure variables are
      assumed to be set to particular values (typically zero), and any
      other predictor variables in the model are assumed to remain the
      same.  It also estimates the log of the ratio of the Scenario 1
      mean to the Scenario 0 mean.  This ratio is known as the
      population unattributable fraction, and is subtracted from 1 to
      derive the population attributable fraction, defined as the
      proportion of the mean of the outcome variable attributable to
      living in Scenario 0 instead of Scenario 1.

      Author: Roger Newson
      Distribution-Date: 14october2010
      Stata-Version: 11

INSTALLATION FILES                                  (click here to install)
(click here to return to the previous screen)

*   For searches and help try:

© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index