Journal of the Royal Statistical Society: Series A (Statistics in Society)

Cover image for Vol. 180 Issue 2

Edited By: J. Carpenter and H. Goldstein

Impact Factor: 1.702

ISI Journal Citation Reports © Ranking: 2015: 13/49 (Social Sciences Mathematical Methods); 24/123 (Statistics & Probability)

Online ISSN: 1467-985X

Associated Title(s): Journal of the Royal Statistical Society: Series B (Statistical Methodology), Journal of the Royal Statistical Society: Series C (Applied Statistics), Significance


A Bayesian approach to Markov modelling in cost-effectiveness analyses: application to taxane use in advanced breast cancer by N. J. Cooper, K. R. Abrams, A. J. Sutton, D. Turner and P. C. Lambert, Journal of the Royal Statistical Society, Series A, Statistics in Society, 166 (2003), 389 - 405


This is a WinBUGS program for evaluating the model described in the above paper. The first part of the program determines the parameters for the Markov model. Where more than one source of data are available meta-analyses are performed.

The second part of the program defines and evaluates the Markov model itself, which is split into four stages. Finally, the incremental costs and utilities are calculated and used to calculate the points for the acceptability curve. All data and initial values are provided.

Nicola Cooper

Department of Epidemiology and Public Health

University of Leicester

22 - 28 Princess Road West





Dataset (22kb)

Selection effects of source of contraceptive supply in an analysis of discontinuation of contraception: multilevel modelling when random effects are correlated with an explanatory variable by F. Steele, Journal of the Royal Statistical Society, Series A, Statistics in Society, 166 (2003), 407 - 423

DISC.RAW is an ASCII file containing data in the format required by aML for a 3-level model. This file is converted to an aML data file by running the file DISC.R2A (using the raw2aml program that comes with aML). Running the two aML programs DISC_STAN.AML and DISC_MULT.AML will produce the results for the standard and multiprocess models respectively (see Tables 7 and 9).

A more detailed description of each file follows. Further details on use of aML can be found in the aML User's Guide.

DISC.RAW. The data have a 3-level structure with cluster at level 1, woman at level 2 and episode at level 3. (Note that in aML level 1 refers to the highest level.) The first two variables in the file are aML 'control variables' required for 3-level data: 1) the cluster ID and 2) the number of episodes per woman. Variables defined at the same level are grouped in the data file, starting with level 3 variables (LOCAL), followed by level 2 variables (WOMANID, EDUC) and finally level 1 variables (LOWER, UPPER, CENSOR, AGE1, AGE3, FWANT3, SOURCE). The level 1 variables are stored as arrays with dimension equal to the maximum number of episodes per woman. LOWER and UPPER are the lower and upper limits of each duration interval (any duration is treated as interval-censored). CENSOR is the censoring indicator (=1 if censored and =0 if uncensored). The covariates are coded as follows:

LOCAL (1=Rabat, Casablanca, 2=other city, 3=town, 4=rural)
EDUC (1=none, 2=primary, 3=secondary+)
AGE1 (1=less than 25 years, 0=other), AGE3 (1=35 or older, 0=other)
FWANT3 (1=using contraception for birth limiting, 0=using for birth spacing)
SOURCE (1=private, 0=public) YEAR (coded 90 to 95)

DISC.R2A. This file reads the ASCII data file and converts it to an aML data file. The first two 'control' variables are not listed in this file. For 3-level data, aML automatically takes the first variable as the level 3 ID and the second variable as the number of level 1 units per level 2 unit. Variables are read in by the level at which they are defined.

To run this file, type RAW2AML DISC at the DOS prompt. An output file DISC.SUM is created and this should be examined carefully to check that the data have been read in correctly. To run aML programs type AML <filename> at the DOS prompt.

DISC_STAN.AML and DISC_MULT.AML are the aML programs for fitting the standard and multiprocess models of Table 7 and 9 respectively.

A piecewise linear spline with nodes at 12, 24 and 36 months is defined for the baseline hazard function in the model for duration of contraceptive use.
Explanatory variables in the equations for discontinuation (Stop) and choice of source (Choice) are defined, with dummy variables created for categorical variables.
4 uncorrelated random effects (2 in each equation) are specified.
A hazards model is specified for the duration of contraceptive use and a probit model is specified for choice of supplier.
The INTRES term specifies a random effect, where the hierarchical level is defined by DRAW= (note that _ID refers to the highest level of the hierarchy, cluster in this case).
Starting values are given for each parameter, starting with coefficients in the order they appear in the model statements, and followed by the random effect standard deviations.

DISC_MULTI.AML runs the multiprocess model in which the woman-level random effects in the hazard equation correlate with the woman-level random effects in the choice of supplier equation. Correlation between the cluster-level random effects across equations is fixed at zero.

Fiona Steele
Bedford Group for Lifecourse and Statistical Studies
Institute of Education
University of London
20 Bedford Way
London WC1H 0AL


Dataset (14kb)