How Science Works

Independent, Dependent and Controlled Variables Explained With Examples

Learn to pick out what you change, what you measure and what you hold steady, with worked experiments, a comparison table and common mistakes.

Key takeaways

  • The independent variable is the factor you set or compare, and the dependent variable is the outcome you record.
  • Controlled variables are held as constant as practical so that a change in the outcome can be traced to the factor you changed.
  • A confounding variable changes along with the independent variable and offers a rival explanation for the result.
  • On a graph, the independent variable usually goes on the horizontal axis and the dependent variable on the vertical axis.
  • The roles belong to a particular study design, so the same quantity can be independent in one and dependent in another.

The independent variable is what you deliberately change. The dependent variable is what you measure to see whether it responds. Controlled variables are the other things you hold steady so they cannot muddle the comparison. In a test of whether water temperature affects how fast sugar dissolves, temperature is independent, dissolving time is dependent, and the amount of water, mass of sugar and stirring are controlled.

A variable is simply anything that can take different values: a length, a temperature, a brand, a yes or no. Sorting them into roles before you start is one of the quickest ways to find holes in a plan.

Three roles in one sentence

A handy template is: "How does changing [independent variable] affect [dependent variable], while [controlled variables] stay the same?" If you cannot fill all three gaps with something measurable, the question needs more work.

Question Independent Dependent Some controlled
Does string length change a pendulum's period? String length Time for one swing and back Release angle, bob, location
Does water temperature affect dissolving? Water temperature Time until no grains are visible Water volume, sugar mass and grain size, stirring
Does fertilizer amount change plant height? Amount of fertilizer Height after a set number of days Seed type, pot, soil, light, water
Does ramp angle change a cart's travel time? Ramp angle Time to cover a marked distance Cart, surface, starting point

Notice that each dependent variable comes with a way of measuring it. "Dissolving" becomes a time with a stated end point, an operational definition that two observers can apply alike.

A worked pendulum example

Suppose you vary the length of a simple pendulum and time its swings. For small swings, physics predicts a period T = 2π√(L ÷ g), where L is the length from pivot to the center of the bob and g is about 9.8 m/s².

L = 0.25 m     T = 2π × √(0.25 ÷ 9.8) ≈ 1.00 s
L = 1.00 m     T = 2π × √(1.00 ÷ 9.8) ≈ 2.01 s

Making the pendulum four times as long doubles the period, because the period depends on the square root of the length. Here L is the independent variable and T is the dependent one. Release angle should be controlled and kept small, since the formula becomes less accurate for wide swings.

A practical tip is to time 10 complete swings and divide by 10. Your reaction error at the start and stop is then spread over 10 periods.

What controlled variables do

If you compare a long pendulum released gently with a short one released from high up, and the periods differ, you cannot say which change produced the difference. Holding the angle fixed removes that ambiguity.

Nothing is held perfectly constant. Room temperature drifts, hands release things slightly differently and materials age. The aim is to keep variation in the important factors small compared with the effect you hope to detect, and to record the ones you cannot hold.

Be selective. A list that includes the color of your shirt wastes attention. Ask which factors could plausibly change the outcome, using what is already known and what a trial run reveals.

Keep "controlled variable" distinct from "control group." The first is a factor held steady. The second is a set of cases used as a baseline, covered in what a control group is for.

Roles in a sugar-dissolving test
One experiment Does temperature affect dissolving time? Watch for Cooling during the trial Controlled Volume, sugar mass, grain size, stirring Independent Water temperature, set by you Dependent Time until grains disappear One experiment Does temperature affect dissolving time? Independent Water temperature, set by you Dependent Time until grains disappear Controlled Volume, sugar mass, grain size, stirring Watch for Cooling during the trial

Confounders: the ones that slip through

A confounding variable varies together with the independent variable and could itself affect the outcome. Say you test two fertilizer amounts, but all the high-amount pots sit by the window. Light is now tangled with fertilizer, and taller plants could reflect either.

You have three main tools. Hold the factor constant, for instance by giving every pot the same light. Balance it, by placing equal numbers of each treatment in each spot. Or let chance decide positions, which is the logic of randomization and also helps with factors you never thought of.

Types of variables

Independent variables need not be numbers. Brand of battery or presence of a lid are categorical variables, taking named values. Length and temperature are continuous, able to take any value in a range. Counts, such as number of leaves, are discrete.

The type shapes the display. With categories, a bar chart or dot plot is natural. With a continuous independent variable, a scatter plot shows the form of the relationship, and you should usually test at least five well-spread values so a curve can reveal itself. Two values can show a difference but cannot tell a straight line from a bend.

When you cannot set the variable

In observational research you record variation that already exists. You cannot assign people to heights or assign weather to cities. Researchers often say explanatory variable and response variable instead, a reminder that nobody manipulated anything.

The distinction matters for conclusions. A link between two recorded variables may arise because the first influences the second, the second influences the first, a third drives both, or chance. Statistical adjustment can address measured confounders but not unrecorded ones.

Time is a common special case. You do not set it, yet it usually plays the independent role when you track cooling or growth.

Sorting variables in a worked scenario

Say you want to know whether the surface under a toy car affects how far it rolls after leaving a ramp. Walk through the roles.

The factor you will change is the surface: wood, carpet and a rubber mat. That is your independent variable, and it is categorical. The outcome is the distance from the bottom of the ramp to where the front of the car stops, in centimeters. That is your dependent variable.

Now list what could also affect distance. Release height sets the car's speed, so mark a release line and let go without pushing. The same car should be used every time. The surfaces should all be level, since even a slight slope would add or remove distance. The joint between ramp and surface should be smooth and alike in all three cases.

Order is a subtler issue. If the car's axles loosen with use and you test carpet last, wear is tangled with surface. Running the surfaces in shuffled order, several times each, spreads that influence around.

Roles can change between studies

No quantity is independent or dependent by nature. In one study, water temperature is what you set to see how fast sugar dissolves. In another, temperature is what you measure to see how well different cup lids keep a drink warm. In a third, it is simply held constant.

Chains of cause make this visible. Light intensity may affect leaf temperature, which may affect water loss. A study could treat leaf temperature as an outcome of light or as an influence on water loss. Your question decides, so write the question first.

Some studies also record several dependent variables, such as height, leaf count and mass. That can enrich the picture, but name the main one in advance. Otherwise it is easy to report whichever happened to move.

Common mistakes

  1. Swapping the roles. Ask which one you choose and which one you wait to find out.
  2. Changing two things at once. Switching both brand and size leaves you unable to assign the difference. A planned design with several factors is different, because every combination is tried.
  3. A vague dependent variable. "How well it works" must become a number, a category or a scored description.
  4. Forgetting units. Record them in the column heading of your data table from the start.
  5. Assuming a variable stayed constant. Measure water temperature at the end as well as the beginning.
  6. Changing the method midway. If you adjust the procedure, rerun earlier trials or report the two sets separately.

A quick planning routine

Write the question using the template. List every factor you think could affect the outcome, then mark each as change, measure, hold, balance or simply record. Decide how many values of the independent variable you will test and how many times you will repeat each.

Then run one practice trial. It usually exposes a controlled variable you missed, such as a thermometer that needs time to settle. Any experiment with hot water, flames or mains-powered equipment needs sensible protection and, for younger experimenters, adult supervision. Once the roles are clear on paper, writing a testable hypothesis is mostly a matter of saying which way you expect the dependent variable to move.

Written for 4Sciences with AI writing tools and not reviewed line by line by a person. Check anything you rely on against a textbook or primary source. Report an error.

Keep reading

All 49 articles in How Science Works →

Latest news on this topic