Home / Science / Weather, ocean and climate / Climatology / Trend and anomaly analyserTool #138

Mann-Kendall trend test and Sen's slope calculator with change point and anomalies

Paste or open a time series (yearly, monthly or any steps) and test for a trend with Mann-Kendall, the Hamed-Rao autocorrelation correction or the seasonal test, get Sen's slope with its confidence interval, a Pettitt change point and anomalies from a baseline period.

Keep it one tap away for everyday use.

Bookmark Trend and anomaly analyser?

Press Ctrl + D now. Your browser opens its own bookmark box, where you choose the name and folder.

  1. Series
  2. Test
  3. Slope
  4. Download
Nothing is uploadedWorks offline once open

Time series

Two columns: the time (a year, a decimal year, or a date such as 2024-07 or 2024-07-15) and the value. Only the first two columns are read. One column of values also works (then times are 1, 2, 3 …). Empty or non-numeric values are skipped. The example is made up. Up to 5,000 values.

Trend

Anomalies

A trend test answers whether values tend to rise or fall over time, not why. Mann-Kendall assumes the values are independent; climate and river series often carry over from one step to the next, which makes trends look more certain than they are. The Hamed-Rao correction allows for that. Monthly data with a yearly cycle need the seasonal test.

Download

What it does

Is a river’s flow falling? Are summers getting warmer at your station? Did air pollution drop after a new rule? These are trend questions, and the usual tools in climate, hydrology and environmental science are the Mann-Kendall test and Sen’s slope. Both use only the order of the values, not their exact size, so a few odd years or a skewed distribution do not throw them off, and they need no assumption that the trend is a straight line.

This tool runs the test, estimates how fast the values change with a confidence interval, looks for a single sudden change point (Pettitt test), and shows each value as an anomaly from a baseline period, like the warming stripes and bar charts in climate reports. Everything runs in your browser.

How to use it

  1. Paste or open your series: a time column and a value column. Times can be years (1990), decimal years (1990.5), or dates such as 1990-07 or 1990-07-15. A single column of values works too. Gaps are fine; rows without a number are skipped.
  2. Choose the test:
    • Mann-Kendall for independent values, such as annual totals.
    • Hamed-Rao correction when one year tends to resemble the next (persistence). It widens the uncertainty based on the autocorrelation of the detrended ranks. “First 3 lags” is the cautious version its authors suggested.
    • Seasonal Mann-Kendall for monthly data with a yearly cycle: each calendar month is compared only with the same month in other years.
  3. Significance level: 5 % is usual. The slope’s confidence interval uses the matching confidence (95 %).
  4. Unit and slope period: for yearly time, per decade is the common way to report climate trends.
  5. Baseline: the years whose mean defines zero for the anomalies (climate services use 30-year periods such as 1991–2020).

What the results mean

  • S counts how many later values are higher minus how many are lower. Z and the p-value say how unusual that would be with no trend. A p-value below your significance level means a significant trend.
  • Kendall’s tau scales S to between −1 and +1.
  • Sen’s slope is the median of the slopes between every pair of points. Its interval comes from the test’s variance (Gilbert’s method, interpolated between ranks).
  • Change point: where the series splits into two parts with the most different levels. A significant change point and a significant trend can both describe the same data; look at the chart before deciding which story fits.

Worked example

The made-up series has 50 annual temperatures from 1975 to 2024. Mann-Kendall gives S = 480, Var(S) = 14,288.7 (with ties), Z = 4.01 and p = 6.1 × 10⁻⁵: a significant rise. Sen’s slope is +0.152 °C per decade (95 % interval +0.087 to +0.223), about +0.75 °C over the record. The series is persistent, so the Hamed-Rao correction multiplies Var(S) by 2.47 and the p-value rises to 0.011, still significant at 5 %. Pettitt places a change point between 2009 and 2010.

FAQ

How many values do I need? At least 10 for a meaningful test; with fewer, the confidence interval cannot be computed.

Does it handle ties? Yes, equal values reduce the variance with the standard correction.

Is it the same as a linear regression? No. Regression fits a straight line by least squares and is sensitive to outliers. Sen’s slope is a robust alternative and pairs naturally with Mann-Kendall.

Where the numbers come from

  • Mann-Kendall test with the tie correction: Mann (1945) and Kendall (1975), as described by Gilbert, R. O. (1987), Statistical Methods for Environmental Pollution Monitoring; Sen's slope: Sen (1968), with Gilbert's confidence interval and Conover's intercept.
  • Autocorrelation correction: Hamed, K. H. and Rao, A. R. (1998), Journal of Hydrology 204, 182 to 196. Seasonal test: Hirsch, Slack and Smith (1982), Water Resources Research 18, 107 to 121. Change point: Pettitt, A. N. (1979), Applied Statistics 28, 126 to 135.
  • Results checked against the open-source pyMannKendall package (MIT licence), used only for testing; no code or data copied.
  • The example series is made up by fibub for illustration.

Standard scientific values, such as constants, atomic weights and melting points, are facts found in every textbook; we name where ours were checked. If you are an author or publisher and want a value, a credit or a table changed or removed, tell us and we will act quickly.

Last updated 2026-11-08.

Change log for Trend and anomaly analyser

  1. Add the trend and anomaly analyser: Mann-Kendall, Hamed-Rao, seasonal test, Sen slope and Pettitt change point (#138) Details on GitHub

Every change to fibub

Related tools

Köppen climate classifier #137 Type or paste 12 monthly mean temperatures and precipitation totals and get the Köppen-Geiger class (such as Csa, Cfb, BWh or Dfb) with every test explained step by step, plus a Walter-Lieth climate diagram showing the dry and wet months. Manning and weir flow calculator #140 Work out the discharge or normal depth in a rectangular, trapezoidal or triangular channel or a part-full pipe with Manning's equation, with velocity, Froude number, critical depth, specific energy, bed shear and a rating curve; and the flow over sharp-crested, V-notch, broad-crested or Cipolletti weirs, or the head for a given flow. SI or US units. Water wave calculator #139 From a wave's period, height and the water depth, get the wavelength (solving the dispersion relation exactly), phase and group speed, energy and power, orbital velocity at the bed, then follow the wave into shallow water with shoaling and refraction to find where and how high it breaks, and the breaker type. Pendulum lab analyser #902 Paste your pendulum lengths and periods (or times for 10 swings) and get g with its uncertainty from a straight-line fit of T² against L, the exact correction for large swings, an optional unknown-length offset, residuals, and how far the small-angle formula is off at any amplitude. Rainfall runoff calculator #141 Estimate the peak flow from a small catchment with the rational method (Q = CiA, Kirpich time of concentration, your own rainfall intensity curve) and the runoff depth, volume and triangular hydrograph from the SCS (NRCS) curve number method, with dry, average and wet ground. Area-weighted C and CN for mixed land use. SI or US units. Volcano plot and PCA #985 Paste or open a metabolite table (peak areas or concentrations, samples in columns) and compare two groups: fold changes, Welch's t-tests, Benjamini-Hochberg FDR q-values and a labelled volcano plot, plus a PCA of all samples with scores, explained variance and the top loadings. Log transforms, missing-value handling and autoscaling or Pareto scaling. Your data stay on your device. Flood frequency analysis #142 Fit GEV, log-Pearson type III and Gumbel distributions to a record of annual peak flows to estimate the 10-, 100- or any-year flood, with bootstrap ranges, the return period of a given flow, the chance of a flood over a span of years, plotting positions and a Grubbs-Beck outlier screen. Paste or open a file. Evapotranspiration calculator #143 Work out daily reference evapotranspiration (ET0) with the FAO-56 Penman-Monteith equation from temperature, humidity, wind and sunshine or radiation, with shortcuts when humidity or radiation is missing, Hargreaves for comparison, crop water use with your own Kc, and a daily table you paste or open for a month or years of weather. Random walk and diffusion simulator #922 Simulate lattice or Gaussian random walks in 1, 2 or 3 dimensions and watch the mean square displacement grow as 2dDt, or paste your own particle tracks to fit the diffusion coefficient, localisation error and anomalous exponent from the time-averaged MSD. Heat capacity fitter #964 Paste or open measured heat capacity against temperature and fit the Debye and Einstein models, with or without an electronic γT term. Get the Debye or Einstein temperature with its standard error, γ, the fit quality of all four models side by side, residuals, and the classic low-temperature C/T against T² line. Download the fit as CSV, image, PDF or Word. Hall effect and van der Pauw analyser #965 Turn van der Pauw and Hall readings into results: sheet resistance with the exact van der Pauw correction, carrier type, sheet and bulk carrier density, Hall mobility, resistivity and Hall coefficient. Use one field with +B and −B to cancel the offset, or fit a whole field sweep. Checks the readings for consistency and downloads the results. Reliability and agreement #40 Check a questionnaire scale with Cronbach's alpha and item statistics, or rater agreement with Cohen's kappa (weighted too), Fleiss' kappa and all six intraclass correlations with 95 % intervals. Matches R's psych package. Uncertainty propagation calculator #25 Type your formula and your measurements with their uncertainties, or paste repeated readings. Get the result with its uncertainty, which input matters most, and a Monte Carlo check. Publication plot maker #27 Paste columns or open a CSV or Excel file and get a clean scientific figure with error bars, sized for a journal column. Download vector SVG or PDF, or PNG at 300 or 600 dpi. Your data stays in your browser. Training load tracker (ACWR, TRIMP, monotony) #488 Log training sessions and get session RPE load, Banister and Edwards TRIMP, the acute:chronic workload ratio (rolling 7/28 days and EWMA), and weekly monotony and strain, with charts. Import and export CSV; kept only in your browser if you choose. Gait and cadence analyser (phone accelerometer) #491 Record your phone's motion sensor while you walk or run, or open a CSV of t, ax, ay, az. The page filters the signal, finds each step, and gives cadence (steps per minute), step and stride time variability, and a spectrum. Nothing leaves your device. Population growth models #303 Compare exponential and logistic growth from a starting size, growth rate r and carrying capacity K, or project an age-structured population with a Leslie matrix and get λ, the stable age distribution, reproductive values, R₀ and generation time. Insect degree-days #319 Paste daily minimum and maximum temperatures and get degree-days by the single sine or simple average method, with lower and upper thresholds, a running total from your biofix, and the date a degree-day target is reached. Runs in your browser. Trap count index #320 Paste insect trap checks (date, site, traps, count) and get catch per trap per day, a moving average, flight peaks, site and week comparisons and flags at a threshold you set. Runs in your browser. Plant growth analysis #324 Paste dry mass and leaf area for plants from two or more harvests and get the classical growth analysis: relative growth rate with its standard error and confidence interval, unit leaf rate (net assimilation rate), leaf area ratio, specific leaf area and leaf weight ratio, using Hunt's formulas for means between harvests. Disease progress (AUDPC) #330 Paste disease severity over time for one or many plots or cultivars. Get the area under the disease progress curve (AUDPC), the area under the disease progress stairs (AUDPS), their relative values, and the apparent infection rate from monomolecular, logistic and Gompertz models, with plots and CSV. Fish length-weight #331 Paste lengths and weights of fish and fit the length-weight relationship W = aL^b on log scales, with an optional bias correction, a t test of b against 3 (isometric growth), Fulton's condition factor K and Le Cren's relative condition Kn for every fish, plots and CSV. Fire Weather Index calculator #337 Run the Canadian Forest Fire Weather Index System over your own daily noon weather (temperature, humidity, wind, rain) from start-up codes. Get the Fine Fuel Moisture Code, Duff Moisture Code, Drought Code, Initial Spread Index, Buildup Index, Fire Weather Index and Daily Severity Rating for every day, with charts. For study and teaching. CPUE trend calculator #339 Work out catch per unit effort (CPUE) from catch and effort records: nominal CPUE by year, a standardised index from a log-linear model with year plus factors such as vessel, area or gear, 95 % intervals, factor effects and the yearly trend, with a chart. Paste records or open a CSV or Excel file. Von Bertalanffy growth fitter #340 Fit the von Bertalanffy growth curve to fish length-at-age data by nonlinear least squares. Get L∞, K and t₀ with standard errors and 95 % intervals, the growth performance index φ', a Ford-Walford plot and charts. Paste ages and lengths or open a CSV or Excel file. Yield per recruit and MSY calculator #341 Work out Beverton-Holt yield per recruit against fishing mortality and age at first capture, with the reference points F0.1 and Fmax. Then get MSY, BMSY and FMSY from the Schaefer or Fox surplus production model, from your own r and K or fitted to a series of catches and CPUE. Notch filter and PSD #346 Paste or open an EEG, LFP or patch-clamp trace (CSV, text, Excel or WAV) and remove 50 or 60 Hz mains hum and its harmonics with IIR notch filters run forwards and backwards. See the Welch power spectrum before and after, band powers (delta to gamma or your own bands), and download the filtered trace as CSV. Calcium imaging ΔF/F #350 Paste or open fluorescence traces for many ROIs (CSV or Excel) and get ΔF/F with a sliding-window percentile, first-N-frames or whole-trace baseline, optional neuropil subtraction, threshold event detection in units of noise, a heat map of all ROIs and CSV downloads. Runs in your browser. Body condition and growth curve tracker #399 Paste or open your weigh records (animal, date, weight and optional body condition score) to get the average daily gain between weighings, fit Gompertz, logistic and von Bertalanffy growth curves with mature weight and growth rate, and see the body condition trend. Nothing is uploaded. Allometric body mass estimator #407 Fit log M = a + b log X to your own reference specimens, or type a published equation's a and b, and estimate body masses of fossils with prediction intervals, %PE, %SEE and a smearing or QMLE bias correction. Plot, CSV and report downloads. Nothing is uploaded. Dendrochronology cross-dating helper #410 Paste or open a dated master (Tucson .rwl or a year table) and an undated ring-width series, and slide one along the other: t-values after Baillie-Pilcher and Hollstein standardisation, Gleichläufigkeit with its significance, a best-matches table and an overlay plot. Nothing is uploaded. Heritage climate and mould risk checker #420 Open a data-logger file (time, temperature, RH) and see the dew point, hours outside your RH and temperature limits, daily RH swings, the longest spell at mould-risk humidity, and a time-weighted preservation index from an Arrhenius rate with your own activation energy, with charts. Nothing is uploaded. Proxy record stacker #508 Open several proxy records (age and value, CSV or Excel), put them on one age grid, turn them into z-scores over a window you choose, flip the ones that run the other way, and stack them (mean or median with a ±1 SD or bootstrap envelope). Compare records with correlations corrected for autocorrelation and a lag scan. ODE solver with phase portraits #548 Type a system of differential equations and solve it in your browser with RK4 or adaptive RK45 (as SciPy). Time plots, phase portrait with direction field and nullclines, equilibria with eigenvalues, a bifurcation diagram, and a heat and wave equation playground. Time series decomposition and ARIMA #566 Paste a series and split it into trend, season and remainder (STL or classical), see the ACF and PACF with confidence bands, try differencing, and fit an ARIMA(p, d, q) model by exact maximum likelihood with forecasts, 80 % and 95 % intervals and a Ljung-Box check. Matches statsmodels. CSV and Excel data profiler #568 Open a CSV or Excel file and see every column at a glance: its type, missing values, unique values, mean, median, SD, quartiles, outliers, histogram or most common values, plus a correlation heatmap. Download the report as a web page, PDF or Word file. Nothing is uploaded. Big-O and runtime comparison plotter #574 Draw how each complexity class grows, add your own formulas in n, and see how long each takes at any input size. Paste measured run times (or open a file, or time built-in algorithms in your browser) and a least-squares fit picks the best Big-O class. Kalman filter playground #639 Try a Kalman filter in your browser. Simulate a noisy sensor with a repeatable seed or paste your own measurements, pick a constant-level or constant-velocity model, move the Q and R sliders, and watch the estimate against the truth, the innovations, the uncertainty and the gain. Download every step as CSV. Pump and system curve #662 Fit a pump curve to points read off the maker's chart, build the system curve from static head and pipe friction, and find the operating point with its efficiency and power. Try pumps in parallel or series, a new speed or a trimmed impeller (affinity laws), and check NPSH available against NPSH required. ECG viewer and HRV #680 Open or paste a single-lead ECG, filter it, find the beats with the Pan-Tompkins method and get heart rate, an RR tachogram, time-domain HRV (SDNN, RMSSD, pNN50), a Lomb-Scargle spectrum with LF and HF power, and a Poincaré plot. For study and research, not for diagnosis. Nothing is uploaded. EMG envelope and fatigue analyser #681 Open or paste a surface EMG recording, band-pass and rectify it, get a moving RMS or low-pass envelope, find each contraction's onset and offset from a rest threshold, and follow muscle fatigue as the median and mean frequency fall in sliding Welch windows, with the slope. For study and research, not for diagnosis. Nothing is uploaded. Decline curve analysis (Arps) #686 Paste or open a well's rate-time history, fit Arps exponential, hyperbolic and harmonic declines by least squares, and forecast to the economic limit with EUR, remaining reserves, an optional terminal decline, and plots on linear and log axes. Control charts and process capability #690 Paste or open process data and draw X̄-R, X̄-S, I-MR, p, np, c or u control charts with limits from your data, Western Electric or Nelson rule flags, and process capability (Cp, Cpk, Pp, Ppk with confidence intervals, expected ppm) with a histogram and normal fit. Calibration interval and drift tracker #691 Paste or open an instrument's calibration history (date, as-found error, uncertainty) and get the drift rate by regression with its confidence interval, a prediction band, the date the error is expected to reach the tolerance limit, and a calibration interval that meets your reliability target, with optional guard banding. Memory and attention tasks #727 Run a digit span or Corsi block test (forward or backward), a visual search task with search slopes, and simple or choice reaction time, in the browser. Get scores, a results table for the session and a CSV of every trial. Vowel formant chart #730 Open a WAV recording, pick a vowel and measure its formants F1, F2 and F3 by linear prediction (LPC), then plot vowels on an F2-F1 chart in Hz or Lobanov z-scores. Paste formant tables from Praat too. Nothing is uploaded. Pitch contour tracker #735 Open a WAV recording and track its pitch (F0) every 10 ms with the YIN method or autocorrelation. Set the pitch range, voicing threshold and smoothing; see the contour in Hz and semitones with mean, range and SD; download CSV. Nothing is uploaded. Supply and demand #738 Enter a demand and a supply curve (straight lines or constant elasticity) and see the market price and quantity, price elasticities, consumer and producer surplus, and what a per-unit tax, subsidy, price ceiling or price floor does: who pays, the shortage or surplus and the deadweight loss, with a chart. Inflation calculator #739 Turn money from one date into money of another with the price index (CPI) numbers you enter, or with a steady yearly rate. Paste a whole index series to rebase it, see inflation each period and year on year, and convert wages or sales into real values. Includes the Fisher equation for real interest rates, exact and approximate. Regression (OLS, IV and panel) #744 Run OLS with classical, robust (HC0 to HC3) or clustered standard errors, two-stage least squares with the first-stage F, or panel fixed effects with entity and time effects, from a CSV. Coefficients, t, p, confidence intervals and R², matching statsmodels and linearmodels. Difference-in-differences #745 Estimate a policy effect by difference-in-differences: the 2 × 2 from group means, or a two-way fixed effects regression on panel data with unit-clustered errors, event-study coefficients with intervals and a pre-trend test. Matches statsmodels. Unit root and cointegration tests #746 Test a time series for a unit root with the augmented Dickey-Fuller test (lags by AIC or BIC) and KPSS, or test several series for cointegration with Engle-Granger. Critical values and p-values come from a seeded simulation in your browser. Polling average #753 Paste opinion polls and get a weighted average by sample size and recency, the margin of error of every poll and of the lead between two parties, and a LOESS or exponential trend with a sampling band, plus a plain account of what the margin of error leaves out. Cohort-component projection #756 Project a population by age and sex in 5-year steps from survival ratios (or life-table nLx), age-specific fertility rates, the sex ratio at birth and net migration by age, with projected pyramids, totals, median age and CSV. Location quotients and shift-share #758 Paste jobs by industry for a region and a reference area. Get location quotients, a shift-share split into national share, industry mix and regional shift, basic and non-basic jobs, the economic base multiplier and the coefficient of specialisation. Gravity model #759 Predict flows between places from their size and distance, or fit the gravity model to your own flows by log-linear least squares and Poisson pseudo-maximum likelihood (PPML). Distances from coordinates or your own. Crime rate calculator #767 Work out crime rates per 1,000, 10,000 or 100,000 people with exact Poisson or Byar confidence intervals. Compare areas or years with rate ratios, an exact test and percent change, and age-standardise rates by the direct method with the Fay–Feuer interval. Runs in your browser. Glacier mass balance and ice flow #828 Turn stake readings and elevation bands into a glacier's mass balance, equilibrium-line altitude and accumulation-area ratio; work out basal shear stress and the speed through the ice with Glen's flow law; and estimate permafrost active-layer depth with Stefan's equation. Tide predictor and harmonic analyser #832 Type or paste tidal constituents (amplitude and phase) and get the predicted water level, the times and heights of high and low water and the windows when the water is deep enough, with nodal corrections for the 18.6-year lunar cycle. Paste a water-level record to get its constituents back by least squares. Not for navigation. Energy balance climate model #834 Move sliders for the solar constant, albedo, emissivity, CO₂, the climate feedback parameter and the ocean's heat capacity, and see the planet's equilibrium temperature, how fast it warms, the ice-albedo feedback with its two stable climates and hysteresis, and the one-layer greenhouse model. Sensor calibration #870 Paste or open a low-cost sensor's readings (with humidity and temperature if you have them) and a co-located reference. The page removes out-of-range, stuck and spike readings (Hampel filter), averages both to the same periods, fits a linear, multilinear (RH, T) or Deming calibration, reports R², RMSE, MAE and bias on fit and test periods, and applies the calibration to new data. CSV in and out.