Lab 06 / Relationships

What correlation leaves out

What can one correlation coefficient hide?

6 min synthetic data fixed seed

Compare positive, negative, near-zero unstructured, and near-zero curved synthetic relationships to see what a linear summary cannot preserve. Change one control at a time, then open the values under the chart before interpreting the picture.

Interactive synthetic lab
runs in this browser

View the values behind this chart

Loading the deterministic simulation...

SEED

What this display answers

Pearson's correlation compresses a point cloud into one measure of linear association. It cannot preserve curvature, clusters, changing variance, or influential observations.

The nonlinear U-shape can have a coefficient near zero even though y changes predictably with x. A scatterplot answers a question the coefficient cannot.

What to notice

  1. Switch among all four patterns and compare the coefficient with the picture.
  2. Use New draw to see which summaries are stable and which details are sampling noise.
  3. Increase the number of points. The intended structure becomes clearer, but the coefficient still describes only its linear component.

The model behind it

The x values are evenly spaced. Seeded normal noise is added to constructed positive, negative, flat-linear, and quadratic patterns.

Noise for the zero-linear examples is orthogonalized against x so their sample linear correlation remains close to zero.

Where the result stops

Correlation is undefined when a variable has no variation and can be unstable with small samples.

A strong correlation does not show causation, direction, or freedom from confounding.