← All animations

๐Ÿฆด Operant Conditioning

B.F. Skinner showed that behaviour is shaped by its consequences. Put an animal in a box with a lever; whether it presses that lever more or less depends entirely on what happens right after. Reinforcement makes a behaviour more likely; punishment makes it less. And when the reward arrives โ€” every time, or unpredictably โ€” produces strikingly different, lawful patterns of responding. Play with all three below.

1. The Skinner box โ€” consequences change the press rate

The rat presses the lever now and then on its own. Pick a consequence below and apply it: a reinforcer (add a treat, or switch off a buzzing shock) makes pressing more frequent; a punisher (add a shock, or take away food) makes it rarer. Watch the lever-press rate meter climb or fall.

Pleasant stimulus
Aversive stimulus
ADD (+)
Positive reinforcementGive a treat โ†’ pressing โ†‘
Positive punishmentGive a shock โ†’ pressing โ†“
REMOVE (โ€“)
Negative punishmentTake the food away โ†’ pressing โ†“
Negative reinforcementSwitch off the shock โ†’ pressing โ†‘
Press rate: 1.0 / s

2. Reinforcement schedules โ€” the shape of responding

How often a press pays off changes how the animal responds. Each line is a cumulative record: the curve only ever rises, and a steeper slope means faster pressing. Tick-marks (โœ“) show when a reinforcer was delivered. Switch schedules and watch the characteristic shape emerge โ€” variable-ratio runs high and steady; fixed-interval scallops.

Variable ratio (VR-10)

3. Why this matters โ€” and why slot machines win

The whole theory in a few lines: