Interpolate a missing weather reading only when a defined application permits an estimate and the surrounding measurements support the method. Keep the measured archive unchanged, mark the estimate, and retain the gap's cause. A short gap is not automatically eligible. Linear interpolation cannot reconstruct rainfall events, gust maxima, daily extremes or measurements that a faulty sensor never made.
This article is about missing-data decisions. For conflicts caused by different sampling, averaging and timestamps, use the separate weather-station time-alignment guide.
Recover real observations before calculating replacements
First determine whether data are missing from the instrument, logger, communications link or dashboard. A delayed upload can leave a platform gap even though original observations remain in local storage. Recover those records with their observation times and identifiers before creating estimates. Check for duplicate uploads and distinguish receipt time from measurement time.
Next identify the record type. A temperature snapshot, an hourly mean, an interval rain accumulation and a gust maximum are different quantities. Nearby snapshots do not automatically reconstruct a missing hourly mean. The relevant time support is as important as the numeric unit.
Inspect status and maintenance records around the gap. Plausible endpoints can still be faulty. NOAA's MADIS surface quality-control documentation separates validity, internal/temporal consistency and spatial checks. Filling a hole is not a substitute for those checks.
A decision table for common gaps
| Variable or situation | Practical treatment |
|---|---|
| Temperature or pressure snapshots during demonstrably smooth conditions | A separately flagged estimate may be acceptable for the defined analysis |
| Temperature during a front or rapid local change | Leave missing unless an independently validated reconstruction is explicitly required |
| Rainfall accumulation or tip counts | Recover original events/counters where possible; do not linearly fabricate interval rain |
| Gust maximum, daily maximum or minimum | Do not claim an interpolated value is the unobserved extreme |
| Wind direction | Do not interpolate scalar degrees across north or calm periods |
| Solar irradiance during moving cloud | Even short gaps can miss rapid changes; do not assume linearity from duration alone |
| Stuck, disconnected or otherwise faulty sensor | Preserve the fault gap; neighboring output is not proof of healthy measurement |
There is no universal ten-minute substitution window and no universal one-record permission/two-record prohibition. Two missing one-second records and two missing hourly records represent very different gaps. Any application-specific limit must consider elapsed time between valid anchors, variable, weather and acceptable uncertainty. Set that policy before inspecting whether a filled chart looks attractive.
Pyranometer example: solar irradiance can change rapidly under cloud, so a short missing interval is not necessarily safe to interpolate.
Linear interpolation: an estimate with explicit assumptions
Suppose a temperature snapshot at 15:00 is absent. The accepted snapshots are 21.4°C at 14:00 and 25.0°C at 16:00. Assume the analysis permits interpolation and supporting observations indicate a gradual change. These inputs are hypothetical, not a NiuBoL measurement record.
For a missing time t between valid times t₀ and t₁:
x_est(t) = x₀ + (x₁ − x₀) × (t − t₀) / (t₁ − t₀).
At 15:00, the time fraction is 60/120 = 0.5, so:
21.4 + (25.0 − 21.4) × 0.5 = 23.2°C.
Store 23.2°C as an interpolated snapshot with the method and anchor references. It is not the observed 15:00 temperature, not the mean over the hour, and not evidence that the day's maximum stayed below 25.0°C. If a front or local event occurred between the anchors, retain the missing record instead.
Averaging real readings at 14:50 and 15:10 also produces a derived estimate of 15:00, not a recovered observation at that time. It may be useful under a suitable policy, but must not silently become normal measured data.
Integrated weather-sensor example. Each output needs its own gap policy; a shared housing does not make all weather variables interpolatable.
Report measured coverage separately from estimate coverage
Consider a hypothetical day with 24 scheduled hourly snapshots. Twenty-one pass observation QC and three are missing. Assume one isolated temperature gap is estimated for a permitted analysis and a consecutive pair is left missing.
| Status | Count | Share of 24 scheduled records |
|---|---|---|
| Accepted original observations | 21 | 87.5% |
| Derived estimate | 1 | 4.17% |
| Still missing | 2 | 8.33% |
| Available including the estimate | 22 | 91.67% |
Measured-data completeness remains 21/24 = 87.5%. The 22/24 = 91.7% figure describes availability including an estimate under this stated convention. It is not evidence that another observation was made. Decide separately whether a mean or other analysis meets its coverage requirement, and disclose how estimated values enter that calculation.
This distinction is important when specifying a weather station. A dashboard can show a complete line while the underlying measurement coverage is incomplete. Ask for status fields and raw exports, not only a plotted completion percentage.
Rainfall needs event and counter evidence
Zero rainfall before and after a missing interval does not establish that the gap was dry. Do not replace it with zero or a straight-line estimate and report a complete daily total. A sum of the available intervals is a partial observed accumulation unless evidence establishes the missing contribution.
A continuous cumulative counter can sometimes preserve the total over a longer gap: the difference between valid counter endpoints can provide the intervening accumulation if resets, rollover, maintenance and counter continuity have been checked. It still does not reveal how that rain was distributed among the missing intervals or recover peak intensity. Original logger tip timestamps may provide that detail if retained. A different station or radar estimate must remain identified as a separate source, not an on-site gauge observation.
Data logger connection example. Retention, restart behavior and export flags must be specified for the selected configuration; they are not demonstrated by this photograph.
Questions about missing records
Q1. Can estimates be used for a display?
Yes, if the purpose allows them and the display distinguishes estimates from observations. Preserve gaps in the raw export and do not feed a cosmetic chart fill into alarms or measured-data statistics without a defined, validated policy.
Q2. Can a daily maximum be calculated after filling temperature gaps?
You can report the maximum of accepted observations with incomplete coverage disclosed. Interpolation does not recover a possible unobserved extreme, so it cannot establish the true daily maximum.
Q3. What fields should a derived-data export contain?
Retain the raw value or missing marker, observation time, units and statistic, QC result, derived value, method, source/anchor records and processing revision. Make it possible to reproduce or remove the estimates without changing the source archive.
A visible gap is better than an invented observation
Recover authentic records first. Use estimates only for an explicitly allowed task, keep them separate, and report original coverage honestly. Rainfall timing, extremes and fault periods need evidence that a straight line cannot supply.
For acquisition-system selection, contact NiuBoL with the sensor list, record definitions, logging interval, outage pattern and required export format. Include a short raw sample and the proposed data logger configuration so storage and retrieval requirements can be checked.











