Design of Experiments
DOE and Scatterplots: Find Interactions a Trendline Can Miss
Use DOE and scatterplots to uncover interaction effects, avoid misleading pooled trendlines, and analyze a reproducible two-factor manufacturing example.
A scatterplot is a useful first look at experimental data, but a flat trendline does not prove that a factor is unimportant. In a designed experiment, the effect of one factor can depend on another. Combining all runs into one plot can hide that interaction.
This guide uses a small, reproducible factorial experiment to show how to connect scatterplots, interaction analysis and a practical process decision.
What a DOE scatterplot adds to the analysis
A DOE scatterplot displays individual responses at the levels of experimental factors. It helps reveal differences in location, spread and unusual observations that a summary alone may conceal. NIST recommends using it alongside mean and standard-deviation plots rather than treating it as a replacement for statistical modeling. See the NIST guide to DOE scatterplots.
A conventional scatterplot has one X variable and one Y variable. For an experiment, its interpretation also depends on what happened to the other factors. A single fitted line averages over those conditions.
Use a scatterplot to inspect the data. Use the experimental design and a suitable model to decide which effects you can estimate.
Worked example: temperature and pressure reverse each other's effect
Imagine a team investigating bond strength. Two controllable inputs are temperature, at 160 or 180 degrees C, and pressure, at 2 or 4 bar. The response is bond strength in MPa.
A two-level full factorial design tests every combination. Two factors therefore require four combinations before replication; see the NIST explanation of full factorial designs.
For this teaching example, each combination is run twice as an independent experimental run. The eight responses below are synthetic. They are deliberately structured to make the interaction visible and are not validated settings for a real bonding process. Run_Order gives one illustrative execution sequence.
Run_Order,Temperature_C,Pressure_bar,A,B,Bond_Strength_MPa
1,180,4,1,1,29
2,160,2,-1,-1,31
3,160,4,-1,1,49
4,180,2,1,-1,51
5,160,2,-1,-1,29
6,180,4,1,1,31
7,180,2,1,-1,49
8,160,4,-1,1,51
The coded factors are A = (Temperature_C - 170) / 10 and B = (Pressure_bar - 3) / 1. Their values are -1 at the low setting and +1 at the high setting.
First scatterplot: the pooled relationship looks flat
Plot Temperature_C on X and Bond_Strength_MPa on Y, using all eight observations. At 160 degrees C the responses are 29, 31, 49 and 51 MPa. At 180 degrees C, they are the same four values.
Both temperature groups have a mean of 40 MPa. A simple least-squares line has a slope of zero and R-squared of zero. A pooled scatterplot against pressure produces the same result.
The wrong conclusion is that temperature and pressure have no useful effect. The pooled plots have averaged away the pattern that determines which combinations work.
Split the plot by pressure to reveal the interaction
Inspect temperature versus strength separately for each pressure level:
- At 2 bar, the mean increases from 30 MPa at 160 degrees C to 50 MPa at 180 degrees C: a change of +20 MPa.
- At 4 bar, the mean decreases from 50 MPa at 160 degrees C to 30 MPa at 180 degrees C: a change of -20 MPa.
If the two conditional mean lines are drawn together, they cross. Raising temperature helps at one pressure and hurts at the other. The difference between those temperature effects is -40 MPa when calculated as high-pressure effect minus low-pressure effect.
That difference of differences is distinct from the conventional two-level factorial interaction effect. With the coding above, the AB interaction effect is -20 MPa and its regression coefficient is -10 MPa.
For plotting, use different colors or separate panels when the plotting tool supports them. Otherwise, inspect separate subsets. A visual suggestion to stratify data does not require assuming that every scatterplot tool automatically creates an interaction plot.
Fit the interaction model, not just a trendline
For this balanced dataset, fitting the intercept, A, B and their product gives:
Predicted bond strength = 40 + 0*A + 0*B - 10*A*B
The fitted mean is 30 MPa when A and B have the same sign, and 50 MPa when they have opposite signs. The model explains 99.01% of the sample variation. The residual sum of squares is 8 MPa squared, with four residual degrees of freedom and a residual standard deviation of 1.4142 MPa.
These results are calculated from the supplied example. The two marginal main effects are zero, yet the response changes sharply across combinations. Removing both factors because their pooled trends are flat would remove the terms needed to describe the interaction.
Include model terms consistent with the experimental design and the engineering question. Review residuals and model adequacy before using predictions. For fractional designs, also review aliasing: apparent effects may combine terms that the design cannot separate. The NIST guide to modeling DOE data explains these distinctions.
What the scatterplot does not establish
This experiment has only two temperature levels and two pressure levels. It does not identify a curved response surface or prove what happens at intermediate settings. A polynomial trendline cannot supply the missing experimental information.
The two observations at each combination must represent independent experimental runs for the stated replication interpretation. Reading the same bonded specimen twice would primarily repeat the measurement, not replicate the production treatment.
Also preserve actual run order, material lot and other operating conditions. A response-versus-run-order plot can flag patterns that deserve investigation. When randomization is feasible, randomize the trial sequence; when factors are hard to change or nuisance conditions require blocking, plan a design and analysis that account for those restrictions.
Turn the result into an engineering decision
If higher bond strength is the objective, two tested combinations have the same fitted mean of 50 MPa: 160 degrees C with 4 bar, and 180 degrees C with 2 bar. The example gives no unique optimum.
Select confirmation trials based on additional requirements such as energy use, cycle time, pressure capacity and material damage. Reproduce the candidate setting under the intended operating conditions and evaluate the relevant quality and cost outcomes. A favorable response in eight synthetic observations cannot replace that confirmation.
If the real objective includes reducing variation, collect enough independent replication to evaluate spread. This example illustrates interaction in the mean; two runs per combination provide very limited information about consistency.
Explore the example in Weibull.app
Open Weibull.app and bring the CSV into your workspace. Use Scatterplot with Temperature_C as X and Bond_Strength_MPa as Y to reproduce the pooled view.
Then use Analyze DOE Results with A and B as the factor columns and Bond_Strength_MPa as the response. Select only those two factor columns; the temperature and pressure columns describe the same factors in physical units, not additional independent inputs. The current analysis includes main effects and two-factor interactions.
The -1/+1 columns make the displayed coefficients directly comparable with the coded equation above. Preserve the physical-unit columns to connect the result back to the operating settings. You can also use Create DOE Design to plan your own experimental worksheet before collecting real response data.
Frequently asked questions
Does zero correlation mean a factor has no effect?
No. In this example the pooled temperature relationship is flat, but its conditional effect changes by pressure. Inspect the study structure and interactions before discarding a factor.
Can I replace DOE with a scatterplot of historical data?
A historical scatterplot can suggest relationships worth investigating. It does not create randomized assignments or remove competing explanations. Decide whether an observational model or a planned experiment is appropriate for the claim you need to make.
Is the highest R-squared model always the best choice?
No. Check whether the design supports the terms, whether the residuals are credible and whether new confirmation runs support the decision. Treat fit to the observed data and performance on new runs as separate evidence.