LOWESS (locally weighted scatterplot smoothing) draws a smooth trend line through a scatterplot of messy data.1Journal of the American Statistical Association. Robust Locally Weighted Regression and Smoothing Scatterplots The result is mainly something to look at, a visual guide to how one quantity tends to change with another, rather than an equation to report.
How LOWESS Builds Its Curve Point by Point
A scatterplot shows each observation as a dot, with one measurement across and one up. At each spot along the horizontal axis, LOWESS fits a simple line or low-degree curve to a subset of points whose horizontal values are nearby.2ITL/NIST. What Is LOWESS Smoothing in Statistics? The fit uses weighted least squares, so nearby points count more and distant points count less.2ITL/NIST. What Is LOWESS Smoothing in Statistics? The curve’s height at that spot comes from that spot’s own local fit.3Journal of the American Statistical Association. Robust Locally Weighted Regression and Smoothing Scatterplots String those local values together and you get a smooth curve that can bend wherever the data bends.
Take temperature against month. Imagine sliding a window along the month axis and looking only at the dots inside it. Within the window, you draw a best-fit line that leans toward the closest dots, mark where that line sits at the window’s center, and slide on. The marked points, connected, become the curve you see.
The window is not a fixed width on the axis. It is defined by how many nearest points it takes in, so it stretches across sparse stretches of data and tightens where dots are crowded. Each spot gets its own window, centered on that spot, so the curve at month 3 never uses exactly the same points as the curve at month 9. Windows overlap heavily, which is why neighboring fitted values are similar and the joined curve looks smooth rather than jagged.
That is also why “locally weighted regression” is a fitting name. Regression just means fitting a line or curve to points. Locally means each fit looks only at a neighborhood, and weighted means close neighbors have more say than ones at the edge.
The method assumes no predefined global relation between the variables.4Copernicus Publications (ISPRS Annals). Robust Locally Weighted Regression For Ground Surface Extraction In Mobile Laser Scanning 3D Data So it can reveal a curve that rises, levels off, then dips, which a single straight line would hide.5Wikipedia. Local regression LOWESS gives a set of fitted values instead of one tidy formula, which is why it is used to explore and check data more than to predict far ahead.
How Nearby Points Get More Say
The traditional weighting rule is called the tri-cube function, a name you may see in software settings.6National Institute of Standards and Technology. What Is LOWESS Smoothing in Statistics? Distances within each window are rescaled so the farthest point sits at exactly 1.6National Institute of Standards and Technology. What Is LOWESS Smoothing in Statistics? A point at the center then gets the most weight, points near the edge get almost none, and points outside get zero.6National Institute of Standards and Technology. What Is LOWESS Smoothing in Statistics?
Because the weights fade smoothly rather than dropping suddenly, the resulting curve is smooth too.5Wikipedia. Local regression Tri-cube combines that smoothness with accurate fits, which is why LOWESS software uses it.5Wikipedia. Local regression Other weighting rules meeting the same basic conditions can also be used.6National Institute of Standards and Technology. What Is LOWESS Smoothing in Statistics? Most tools apply tri-cube automatically; the span matters far more.
Choosing the Span, the Setting That Matters Most
The span is how local the smoother is, the share of the data each local fit draws on.7UC Berkeley Department of Statistics. Risk Optimization and Bias-Variance Trade-Off A span of 0.5 means each fit uses about half of all the points. With 100 dots, that is roughly the 50 nearest to the spot being estimated. Raising the span to 1.0 means every fit uses every point, with the weights still favoring the nearest ones.
Smaller spans, such as 0.25, give flexible, wiggly curves.8MetricGate. LOESS/LOWESS Regression Calculator Larger spans, around 0.75 to 1.0, give smoother curves that can miss real bends.8MetricGate. LOESS/LOWESS Regression Calculator
To choose by eye, try a few spans, for example 0.25, 0.5 and 0.75, on the same plot. A curve that zigzags between neighboring dots is chasing noise. A curve that ignores an obvious hump is too smooth. Pick the smoothest curve that still keeps the features you trust.
One common data-driven way to choose this kind of setting is cross-validation.9The Annals of Statistics. Cross-validation in nonparametric regression with outliers It leaves out some points and fits the curve without them, then checks how well the curve predicts the points you left out. Repeat that for several spans and keep the one that predicts best.
Many tools pick a span of around two-thirds automatically. That may suit one dataset and blur another, and checking one smaller and one larger span takes seconds.
The choice matters because results such as where a feature starts and ends can shift with different span choices.10PubMed Central. Optimized LOWESS normalization parameter selection for DNA microarray data In one cancer study the span was chosen arbitrarily and not reported, making results hard to check.10PubMed Central. Optimized LOWESS normalization parameter selection for DNA microarray data Note the span you used whenever you share a LOWESS curve.
Why LOWESS Resists Stray Points
An outlier is a point far from the rest, often from an error or an unusual event. After a first fit, the robust version down-weights points that sit far from the curve, based on how far off they are.4Copernicus Publications (ISPRS Annals). Robust Locally Weighted Regression For Ground Surface Extraction In Mobile Laser Scanning 3D Data The curve is then refit with these new weights.4Copernicus Publications (ISPRS Annals). Robust Locally Weighted Regression For Ground Surface Extraction In Mobile Laser Scanning 3D Data Fitting and down-weighting repeat until two fits in a row barely differ.4Copernicus Publications (ISPRS Annals). Robust Locally Weighted Regression For Ground Surface Extraction In Mobile Laser Scanning 3D Data That way a single wild point has much less pull on the curve.
The gap that drives this is called a residual: the vertical distance between a dot and the fitted curve at that spot. Dots with large gaps are treated as suspicious and given smaller weights. Dots close to the curve keep nearly full weight, so the fit leans on the well-behaved bulk of the data.
One pass is not enough because the first curve is itself pulled a bit toward a stray point, so the gaps it shows are somewhat understated. Refitting with reduced weights gives a better curve, and that gives a more honest measure of which dots are stray. A few rounds let the curve and the weights settle on each other.
Down-weighting hides odd points from the curve, not from your data. A stray point may be a real event worth investigating, so look at the dots, not just the line.
LOWESS, LOESS and Simpler Smoothers
The two names, LOWESS and LOESS, are often used for the same idea.11University of Texas at Austin. What Is LOWESS Smoothing in Statistics The difference, when there is one, is the local fit: LOWESS commonly fits local straight lines, while LOESS often fits local gentle curves (degree 2).12MetricGate. LOWESS vs LOESS Smoothing The curved version handles the edges of the data more smoothly.12MetricGate. LOWESS vs LOESS Smoothing
Some programs offer a single function that can do either, with the local fit degree as a setting. A chart labeled one name may have been made with the other kind of fit, so checking the settings matters. If the curve looks odd at the ends, try the degree-2 option, and name in your report which version you used.
The simplest local method just averages nearby points.5Wikipedia. Local regression That averaging can be biased near the ends of the data,5Wikipedia. Local regression because it leans inward at the left and right edges.13MetricGate. Nadaraya-Watson Kernel Regression Explained At the far right, for example, there are neighbors only on the left. If the trend is rising, the average of those neighbors sits too low. A local line follows the slope and extends it to the edge instead, so fitting one greatly reduces that edge error.5Wikipedia. Local regression Local lines also cope better where points are sparse or unevenly spread.13MetricGate. Nadaraya-Watson Kernel Regression Explained
Where LOWESS Shows Up
LOWESS on Ottawa weather from 1890 to 2019 showed warming temperatures and a shift toward rain over snow.14Environments. Precipitation and Temperature Trends and Cycles Derived from Historical 1890–2019 Weather Data for the City of Ottawa, Ontario, Canada
For Australian temperatures, LOESS gave better, smoother fits than double exponential smoothing.15Meteorological Applications. Locally weighted scatter‐plot smoothing for analysing temperature changes and patterns in Australia That makes local fitting a strong reference point when comparing time-series methods, though it still describes the past record, so using it to predict far beyond the data needs extra caution.
A very smooth LOWESS curve can also strip out a seasonal cycle so the longer trend stands out.16kls2177.github.io. Filtering in the Time Domain: Part I Temperature goes up and down every year, and that cycle can swamp a slow trend. A curve with a large span averages across whole cycles, so the up-and-down washes out and the slower drift underneath remains.
LOWESS is also handy for checking other models. A LOWESS curve on a scatterplot gives a visual estimate of the average trend.11University of Texas at Austin. What Is LOWESS Smoothing in Statistics That can show whether a straight-line model really fits. Plot the model’s leftover errors against the predictor and add a LOWESS curve. A flat curve near zero is consistent with the line fitting, while a clear bend suggests a curved relationship may have been missed. LOWESS bands around a model’s errors can also show whether their spread changes across the data.17OSF Preprints. Quantifying Heteroscedasticity in Linear Models Using Quantile LOWESS Intervals
In the lab, robust local regression is used to correct dye biases in gene microarray experiments.18PubMed Central. Normalization for cDNA microarray data: a robust composite method addressing single and multiple slide systematic variation It has also helped map regions of unusual gene copy numbers in prostate cancer.10PubMed Central. Optimized LOWESS normalization parameter selection for DNA microarray data
Limits and How to Show Uncertainty
The curve shows a pattern, not a cause. LOWESS shows how one quantity tends to move with another, and nothing in the method says one drives the other. A third factor could push both up and down together, producing the same curve. Explaining why the pattern exists takes knowledge of the subject or a study designed for that question.
It also says little beyond the range of the data. Near the ends, each fit already uses points from one side only, so the curve is less reliable there. Beyond the last dot there is nothing to fit, and no formula exists to continue the line. Trends often change outside the range you observed, so a continued curve would be a guess. With many points and many fits, the method can also be slow on huge datasets.
To show how sure you can be, bootstrapping estimates uncertainty by refitting LOWESS on many random resamples of the data.19statsmodels. LOWESS Smoother You draw points from your data at random, with repeats allowed, fit LOWESS, and repeat hundreds of times. The spread of those curves forms a confidence band; shade the area most of the curves fall in. Where the band is wide, such as in sparse regions, the curve deserves less trust.

