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: graphing a 3 way interaction with mi data

From   Scott Merryman <>
Subject   Re: st: graphing a 3 way interaction with mi data
Date   Thu, 31 Jan 2013 21:56:09 -0600

On Thu, Jan 31, 2013 at 2:09 PM, Tomeka Davis <> wrote:
> mi estimate, saving (miest): svy: logit private race ses povrate race_ses ses_povrate race_ses_povrate
> However, I am not clear on how to generate a graph plotting the predicted probability of private school attendance by race, ses, and poverty rate, particularly after the mi command.

This may not be too helpful as -margins- is not available after -mi
estimate-, however it is easy to plot continuous by continuous by
categorical interactions using -margins- and -marginsplot-.

For example:

sysuse nlsw88.dta,clear
logit married ibn.race ibn.race#(c.wage c.grade c.wage#c.grade), nocon
margins race, at(grade=(0(6)18) wage = (10(10)40))
marginsplot , bydim(race) plotdimension(grade, allsimple)
legend(subtitle(Education) rows(1)) byopts(rescale) noci

This example is adapted from Michael Mitchell's Interpreting and
Visualizing Regression Models Using Stata, chapter 13  "Continuous by
continuous by categorical interactions"

*   For searches and help try:

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