A forest plot of a logistic regression shows every predictor's adjusted odds ratio on one chart. Each predictor gets a row: a square for the odds ratio and a horizontal line for its 95% confidence interval. A vertical line at an odds ratio of 1 marks no association. This is not a meta-analysis: there is no pooled diamond, because each row is a different predictor from the same model.
What you need before you draw it
- The fitted model. In SPSS, run Analyze > Regression > Binary Logistic, put the outcome in Dependent and the predictors in Covariates (declare categorical predictors under Categorical).
- Odds ratios with confidence intervals. Under Options, tick CI for exp(B) (95% by default). The Variables in the Equation table then shows B, S.E., Wald, df, Sig., Exp(B), and the lower and upper limits for Exp(B).
- The units of each predictor. An odds ratio is per one-unit increase, so "per year" and "per point" belong in the row labels.
To compute them by hand: OR = exp(B), and the 95% CI is exp(B − 1.96 × SE) to exp(B + 1.96 × SE). That interval is symmetric around B on the log scale but not around the OR, which is why the plot needs a log axis.
The worked example
A study of 100 patients recorded whether each took their medication as prescribed (19 adhered, 81 did not), along with age, depression score and whether they had insurance (62 yes, 38 no). A logistic regression with all three predictors gave χ²(3, N = 100) = 12.67, p = .005.
| Predictor | B | SE | z | p | OR | 95% CI |
|---|---|---|---|---|---|---|
| Age (per year) | 0.03 | 0.02 | 1.46 | .144 | 1.03 | [0.99, 1.07] |
| Depression (per point) | −0.06 | 0.03 | −1.96 | .050 | 0.94 | [0.88, 1.00] |
| Insurance (yes vs no) | 1.52 | 0.69 | 2.21 | .027 | 4.55 | [1.18, 17.48] |
![Forest plot of adjusted odds ratios of adherence on a log axis: age 1.03 [0.99, 1.07], depression 0.94 [0.88, 1.00], insurance 4.55 [1.18, 17.48], with a dashed line at an odds ratio of 1.](/guide-figures/forest-plot-odds-ratios-logistic-regression.png)
Reading it:
- Insurance sits well to the right of 1: with age and depression held constant, the odds of adherence were 4.55 times higher with insurance, 95% CI [1.18, 17.48]. The interval is wide because only 19 patients adhered, so the size of the effect is uncertain even though the interval excludes 1.
- Age has an odds ratio of 1.03 per year, and its interval [0.99, 1.07] crosses 1, so the data are compatible with no association.
- Depression has an odds ratio of 0.94 per point, about 6% lower odds of adherence per point. Its upper limit rounds to 1.00 and its p rounds to .050: this predictor sits on the .05 boundary, so report the numbers as they are and do not build a conclusion on it.
Per-unit odds ratios depend on the unit. The odds ratio per decade of age is exp(10 × B), not 10 times the yearly one, so state the unit in each row, or rescale the predictor before fitting if a decade is the more useful unit.
How to draw it in R
fit <- glm(adherence ~ age + depression + insurance,
family = binomial, data = dat)
or <- exp(coef(fit))[-1]
ci <- exp(confint.default(fit))[-1, ] # Wald 95% CI, as SPSS prints
y <- rev(seq_along(or))
plot(or, y, log = "x", pch = 15, xlim = c(0.5, 20), yaxt = "n",
xlab = "Adjusted odds ratio (log scale)", ylab = "")
segments(ci[, 1], y, ci[, 2], y)
abline(v = 1, lty = 2)
axis(2, at = y, labels = names(or), las = 1)confint.default() gives Wald intervals that match SPSS. confint() on a glm gives profile-likelihood intervals, which can differ slightly, especially in small samples; say which you used. The forestplot package (forestplot() with labeltext, mean, lower, upper, xlog = TRUE and zero = 1) draws a more polished version from the same numbers.
How to draw it in Excel from the SPSS table
- Copy the Variables in the Equation table into Excel. Keep the predictor names, Exp(B) and the lower and upper limits.
- Add a row-number column (3, 2, 1, so the first predictor is at the top), and two error columns: minus = Exp(B) − lower, plus = upper − Exp(B).
- Insert an XY (Scatter) chart with Exp(B) as X values and the row numbers as Y values.
- Add error bars, delete the vertical ones, and set the horizontal ones to Custom > Specify Value with the plus and minus columns.
- In Format Axis, tick Logarithmic scale for the x-axis.
- Add a second series with points (1, 0) and (1, 4), drawn as a straight dashed line, for the line of no association at 1.
- Hide the y-axis numbers and add the predictor names as data labels (Value From Cells).
SPSS has no forest plot option inside Binary Logistic, so most SPSS users draw it in Excel or R this way.
The APA 7 format template
"In a logistic regression predicting [outcome] from [predictors], [predictor] was associated with [higher/lower] odds of [outcome], OR = X.XX, 95% CI [X.XX, X.XX], p = .XXX (Figure [N])."
Want to see it written from data? Run this test on sample data in KyroStat: free, no file needed, and it does not use your free tests.
Worked example: "In a logistic regression predicting medication adherence from age, depression score and insurance, χ²(3, N = 100) = 12.67, p = .005, having insurance was associated with higher odds of adherence, OR = 4.55, 95% CI [1.18, 17.48], p = .027 (Figure 1). Age, OR = 1.03, 95% CI [0.99, 1.07], p = .144, and depression score, OR = 0.94, 95% CI [0.88, 1.00], p = .050, had intervals that reached or crossed 1."
Mistakes reviewers catch
- A linear axis. On a linear axis an OR of 0.5 looks closer to 1 than an OR of 2, though both are equal and opposite. Use a log axis.
- Unadjusted odds ratios labelled as adjusted. Say whether each OR comes from the multivariable model or from one predictor at a time, and list the covariates in the figure note.
- Missing units. "Age 1.03" means nothing without "per year".
- Reference category not stated. For a categorical predictor, label the row "yes vs no" or name the reference group.
- Mixing interval types. Wald and profile-likelihood intervals differ; use one kind throughout and say which.
- Reading the plot as a meta-analysis. There is no pooled estimate across predictors, so there should be no diamond.
Frequently asked questions
Is there a forest plot option in SPSS Binary Logistic? No. Binary Logistic prints the numbers; draw the plot in Excel or R from Exp(B) and its limits.
Can I plot a linear regression the same way? Yes, as a coefficient plot: each B with its 95% CI on a linear axis, with the reference line at 0 instead of 1.
Should the intercept be on the plot? No. The intercept is the odds at zero on every predictor, not an association, and it sits on a different scale from the predictors.
What if one interval is very wide? Keep it. A wide interval shows the estimate is imprecise, usually from few events or a rare category. Extend the axis, or mark a clipped end with an arrow and say so in the note.
How many predictors can the model support? A common rule of thumb asks for about 10 events per predictor. With 19 events and three predictors, this example is near that limit, which is another reason for the wide insurance interval.
Making it in KyroStat
Upload your data to KyroStat and run a logistic regression on a yes/no outcome. KyroStat reports each predictor's odds ratio with its 95% CI from the engine, and you can ask Kyro, the assistant in the sidebar, to draw them as a forest plot.
Related guides
- How to report a logistic regression in APA 7: the full write-up, with model fit and a table.
- How to make a forest plot in Excel: the scatter-and-error-bar method in detail.
- How to read a forest plot: squares, lines, the line of no effect and the diamond.
- Which statistical test should I use?: when logistic regression fits your outcome.