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]

Re: st: detonator plot with three grouping variables

From   "Roger B. Newson" <>
Subject   Re: st: detonator plot with three grouping variables
Date   Thu, 09 May 2013 14:50:38 +0100

To plot multi-group detonator plots, you should use -eclplot- with the -by()- option, the -supby()- option, or even both. The -by()- option does by-groups in the usual way, and the -supby()- option allows you to create groups of adjacent bars, in which each bar in the group has a different color (or shade of gray).

A tutorial on -eclplot- (including detonator plots and the -supby()- option) is available as a presentation originally given at the 2005 UK Stata User Meeting (Newson, 2005).

I hope this helps.

Best wishes



Newson R. Generalized confidence interval plots using commands or dialogs. Presented at the 11th UK Stata User Meeting, 17-18 May, 2005. Download from

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
Web page:
Departmental Web page:

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

On 09/05/2013 13:09, Ronnie Babigumira wrote:
Dear David, Nick, and Roger,

Many thanks for your feedback.

I agree with David and Nick, however, the team with which I am working on this settled for the bar chart. The reviewers liked how the data were displayed but requested CI's be added. I will use the links you have provided to make the case against using the detonator/dynamite plots but there is an even simpler case which is that the resulting plot will be quite busy. It is for this reason that I must make the plot. I will look at -ciplot- which, I think, does what David suggests.

Nick, I used graph bar for illustrative purposes (to show the 3 level structure of the data). The example has 2 levels, race and socio-economic status while our data has 3. I could do three different graphs for each of the highest levels (e.g rep78 in the demo example) but the point was to have one graph. On -stripplot- I am a true convert/believer and use it whenever I have the opportunity to.

Roger, thanks for the additional information on eclplot. I looked at the examples but it was not clear to me how to do the three levels. It is entirely possible that I am looking at this the wrong way :-(

Best regards,


*   For searches and help try:

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