Factorial Design (DOE)
A way to analyze the main effects and interactions of several experimental conditions together, to see which combinations change the outcome.
To make a factory's product stronger, should you adjust the temperature first? What happens if you raise the pressure? And could raising temperature and pressure together have a bigger effect than changing each one on its own?
Factorial design is a way to combine several experimental conditions systematically and analyze the effect of each condition and how they influence one another. It is the most widely used design in the design of experiments (DOE).
Where one-way ANOVA looks at mean differences across a single factor, a factorial design handles two or more factors at once. What matters most is that it can detect interactions, where the effect of one factor depends on the level of another.
It is used in research where several conditions have to be tuned, such as manufacturing processes, food development, agricultural experiments, and service operations. In this article we'll walk through a single example covering the basic idea of factorial design, main effects and interactions, the run layout and results table, interpreting the ANOVA, how it differs from other analyses, and what to watch out for.
What is factorial design (DOE)?
It changes two or more experimental conditions at the same time and evaluates how they affect the outcome.
Factorial design is a way of designing and analyzing experiments that combines the levels of several experimental factors systematically to estimate the main effect of each factor and the interactions between factors. A full factorial design runs every combination, while a fractional factorial design runs only a selected subset.
Why is this better than changing one factor at a time?
If you change only one condition at a time, it's easy to miss interactions.
If you vary only temperature while holding pressure and processing time fixed, you learn the effect of temperature only under those conditions. But if raising the temperature has a bigger effect at high pressure, that difference is a temperature × pressure interaction.
Because a factorial design observes combinations of conditions, it can analyze not only the average effect of each factor but also cases where performance improves or worsens under particular combinations. The catch is that the cost of the experiment grows quickly as the number of combinations increases.
How does factorial design work?
You first plan the factors, levels, combinations, replicates, and random assignment.
① Choose the factors and levels
In this example we set two levels for each of three factors: temperature (160/180°C), pressure (20/30 bar), and processing time (20/30 min).
② Lay out every combination
With three two-level factors, there are 2³ = 8 experimental conditions. Replicating each combination with 3 independent production batches gives 24 runs.
③ Randomize the run order
Randomize the run order so it isn't confounded with equipment wear, operators, or dates, and record blocks (day, machine, etc.) separately where needed.
④ Estimate main effects and interactions
A model evaluates the mean difference for each factor, the two-factor interactions, and the three-factor interaction.
Real-world example: optimizing product strength in a manufacturing process
We compare every combination of temperature, pressure, and processing time.
A hypothetical factory evaluated the tensile strength (MPa) of its product under different process conditions. Assume 24 independent batches were randomly assigned to the 8 conditions, with three measurements per condition. The values below are data constructed for learning purposes.
| Condition | Temperature | Pressure | Time | Strength, 3 measurements (MPa) | Mean |
|---|---|---|---|---|---|
| 1 | 160°C | 20 bar | 20 min | 52.0, 53.0, 54.0 | 53.0 |
| 2 | 160°C | 20 bar | 30 min | 55.0, 56.0, 57.0 | 56.0 |
| 3 | 160°C | 30 bar | 20 min | 53.0, 54.0, 55.0 | 54.0 |
| 4 | 160°C | 30 bar | 30 min | 56.0, 57.0, 58.0 | 57.0 |
| 5 | 180°C | 20 bar | 20 min | 56.0, 57.0, 58.0 | 57.0 |
| 6 | 180°C | 20 bar | 30 min | 61.0, 62.0, 63.0 | 62.0 |
| 7 | 180°C | 30 bar | 20 min | 67.0, 68.0, 69.0 | 68.0 |
| 8 | 180°C | 30 bar | 30 min | 72.0, 73.0, 74.0 | 73.0 |
The example was generated with fixed rules to illustrate the effects between factors. It is not data that validates a real process or proves a causal effect.
How do you calculate a main effect?
Compare the overall means at the high and low levels of one factor.
Averaging over all levels of the other factors, the mean strength is 55 MPa at 160°C and 65 MPa at 180°C. So the main effect of temperature is +10 MPa.
| Factor | Low-level mean | High-level mean | Main effect |
|---|---|---|---|
| Temperature | 55 MPa | 65 MPa | +10 MPa |
| Pressure | 57 MPa | 63 MPa | +6 MPa |
| Processing time | 58 MPa | 62 MPa | +4 MPa |
A main effect here is a mean difference that depends on the levels included in the analysis and on how the other factors were laid out. Significance has to be tested separately, using the error from the replicate runs.
How do you interpret an interaction?
Check whether the effect of one factor depends on the level of another.
At 20 bar, raising the temperature from 160°C to 180°C increases strength from 54.5 MPa to 59.5 MPa, a gain of 5 MPa; at 30 bar it rises from 55.5 MPa to 70.5 MPa, a gain of 15 MPa.
How do you tell main effects from interactions?
An average effect is not the same as an effect that changes from condition to condition.
| Effect | Pattern seen in the example | Key interpretation |
|---|---|---|
| Temperature main effect | 180°C averages 10 MPa higher than 160°C | Temperature difference averaged over all conditions |
| Pressure main effect | 30 bar averages 6 MPa higher than 20 bar | Pressure difference averaged over all conditions |
| Time main effect | 30 min averages 4 MPa higher than 20 min | Time difference averaged over all conditions |
| Temperature × pressure | Effect of raising temperature: 5 MPa at 20 bar, 15 MPa at 30 bar | The temperature effect depends on pressure |
If an interaction is large or statistically important, don't justify the process choice with a single main-effect number; it's better to check the simple effects within each condition.
What do you look for in the ANOVA table?
Compare the variation from each effect with the error between replicate runs.
In a balanced 2³ full factorial design you can estimate the main effects A, B, and C, the two-factor interactions AB, AC, and BC, and the three-factor interaction ABC. With 24 independent runs, the model effects have 7 degrees of freedom and the residual has 16.
| Effect | df | What to check |
|---|---|---|
| Temperature (A) | 1 | F, p, effect size |
| Pressure (B) | 1 | F, p, effect size |
| Processing time (C) | 1 | F, p, effect size |
| A×B, A×C, B×C | 1 each | How effects change across conditions |
| A×B×C | 1 | Whether a two-factor interaction depends on the third factor |
| Error | 16 | Variation between replicate runs |
The example focuses on understanding the effects by designing the data pattern. Real significance testing should be done only after reviewing model choice, residual assumptions, and the independence of the runs.
Which settings matter when you design the experiment?
Run order, replication, and blocking determine how much you can trust the results.
| Setting | Meaning | Practical tip |
|---|---|---|
| Replication | Apply the same condition to independent experimental units | Don't count re-measuring the same sample as an independent replicate |
| Randomization | Arrange the run order of conditions at random | Reduce systematic effects of time trends or equipment changes |
| Blocking | Group runs by nuisance factors such as day or machine | Design so that conditions and blocks don't fully overlap |
| Choice of levels | Set a low and high level for each factor | Choose a range that is practical and safe to run |
| Sample size | Consider the error and the power you want | State the cost, effect size, and interaction-detection goals |
Experimental design isn't something you change after you see the results. The variables and levels, the number of replicates, and the randomization method must be set before the experiment.
What to watch out for in factorial design
Check independence of observations, constant variance, and the scope of the model together.
① Check the residuals and variance
Review the residuals for normality, equal variance, outliers, and process drift. If needed, consider a transformation or a different model.
② Identify the independent experimental units
Measuring the same batch several times is not the same as producing several independent batches. Avoid pseudoreplication.
③ Don't ignore interactions
If interactions matter and you pick the best condition from main effects alone, you can make the wrong process decision.
④ Verify the best condition separately
The maximum in a factorial design is a result within the factor levels you chose this time. Verify the recommended condition with a separate confirmation run, and don't rush to generalize beyond the range of the experiment.
How does it differ from other analyses?
They differ in how the factors are laid out and in what the study is for.
| Analysis | Main purpose | Difference from DOE |
|---|---|---|
| One-way ANOVA | Compare group means across one factor | Doesn't handle other factors or interactions |
| Two-way ANOVA | Test the main effects and interaction of two factors | DOE also emphasizes the design itself, including factor levels, combinations, randomization, and replication |
| Full factorial design | Run every combination of factor levels | Can estimate every main effect and interaction |
| Fractional factorial design | Run a subset of combinations to save on experiments | Some effects may be confounded with each other (aliasing) |
| Response surface methodology (RSM) | Explore curvature and the optimum for continuous factors | Models curvature that is hard to detect with two-level designs alone |
Effects in a factorial design can be tested with ANOVA or linear regression. Design of experiments is the framework for the design, and ANOVA is one of the tools for analyzing the resulting data.
How do you report factorial design results?
Connect everything from the design to the effects and interactions to follow-up verification.
In a paper or technical report, first present the factors and their levels, whether the design is full or fractional factorial, the number of replicates and the independent experimental units, the randomization and blocking setup, and the response variable. Then report the main-effect and interaction estimates, confidence intervals, F-tests, and p-values as appropriate.
In a real report, add the standard errors and confidence intervals of the estimates, appropriate test statistics, model diagnostics, and the results of confirmation runs.
Where can you use factorial design?
It fits fields where you test several conditions at once and look for the best combination.
| Field | Example factors | Response variable |
|---|---|---|
| Manufacturing | Temperature, pressure, time | Product strength, defect rate |
| Food | Baking temperature, moisture, mix ratio | Texture, quality score |
| Agriculture | Fertilizer level, irrigation, light | Yield |
| Service operations | Staffing, operating hours, procedures | Wait time, throughput |
| Online experiments | Design, offer, message | Conversion rate, click-through rate |
If the response variable isn't continuous, you can estimate the factors and interactions with a suitable generalized linear model such as binomial or Poisson. The principles of experimental design stay the same, but the analysis model is chosen to fit the nature of the outcome data.
Factorial design looks at the effects of individual conditions and the interactions between them together.
To find the best conditions, you need to check not only which factors matter but also which combinations change the outcome.
In the manufacturing example, we set temperature, pressure, and processing time at two levels each and compared all eight conditions. Temperature had the largest average main effect, but the gain in strength from raising the temperature differed between high and low pressure. So there are limits to choosing the best condition from the average effect of a single factor.
In real research you need to check whether the experiment had enough replication and randomization, and whether the residual and variance assumptions hold. Interpret main effects and interactions together, and even the condition that gave the best result in the experiment should not be declared the optimum for the whole process without a separate confirmation run.
Factorial design combines the levels of several factors to estimate main effects and interactions together. When there is an interaction, the effect of one factor depends on the level of another, so you need to check the results condition by condition. Randomization, independent replicates, and assumption checks are important, and the best condition should be verified with a confirmation run.