A robot signal review can show a much smaller residual after fitting separate baselines on either side of a selected sample. That smaller residual does not establish that an original step was a sensor fault, that the acquisition improved, or that the physical signal became continuous. The fitted baseline may simply have absorbed the step the reviewer needed to inspect.

An original eight-sample model makes this distinction explicit. It compares one global straight-line fit with two independent straight-line fits, then subtracts each fitted baseline. The values are synthetic and unitless. No real sensor, robot controller, calibration routine, or production signal was operated.

Preserve the step in the raw record

Use sample indices 0 through 7 and values [0,0,0,0,10,10,10,10]. The first four samples occupy a level of zero; the final four occupy a level of ten. Index 4 is the first sample in the second group. The difference between samples 3 and 4 is ten under this declared construction.

These are sample indices, not seconds. The model does not provide a sampling period or claim a physical slew rate. Calling the boundary an event time would require a separate mapping between indices and acquisition timestamps, which is intentionally absent from this small example.

State what the fit can remove

SciPy's detrend reference describes linear detrending as subtracting a linear least-squares fit. Its breakpoint parameter specifies index boundaries between independently fitted parts, and applies to linear detrending. That documentation supplies a useful interpretation of segment-wise baseline removal, rather than evidence that a particular segmentation is physically justified.

The local calculation uses NumPy's least-squares solver directly. SciPy is not installed in the tested interpreter, and scipy.signal.detrend was not called. This is an independently executed mathematical model of global and segmented line subtraction, not an asserted output from the SciPy API or a validation of every option it supports.

Fit one line across all eight samples

For the global fit, create a design matrix with one column containing the sample index and another containing ones. Fit coefficients m and c in the relation m times index plus c. NumPy's least-squares reference defines the solver's residual-norm minimization; the matrix and inputs here are original.

The executed model returns slope approximately 1.904762 and intercept approximately -1.666667. In exact arithmetic for these inputs, the coefficients are 40/21 and -5/3. This line compromises across the two levels instead of following either plateau exactly.

Subtracting the global fit leaves a residual RMS of approximately 2.439750, computed over all eight samples. That number describes this fitted example's remaining squared deviations. It is not an instrument noise specification, a confidence interval, or evidence of actual robot vibration.

Fit the two parts independently

Now split the same raw vector into the half-open slices [0,4) and [4,8). Each part has four samples and its own slope and intercept. The first part is fitted by a zero-valued constant line, which is also a valid straight line with zero slope. The second part is fitted by a line at ten.

The two fitted baselines therefore differ by ten across the selected boundary. No shared intercept or continuity condition was included in the two solves. Joining their fitted values produces a segmented baseline that reproduces the original step, rather than smoothing it into a continuous physical trajectory.

After subtracting that segmented baseline, every residual has absolute magnitude below 10 to the power of minus 12 in the executed calculation. The exact mathematical residual is zero for these constant segments; the reported tolerance allows for floating-point arithmetic. It is not a recommended acceptance threshold for any sensor.

Explain why the residual became smaller

The segmented model can represent the original vector exactly because it gives the two levels separate fitted parameters. A global straight line cannot represent this particular step exactly. The improved residual follows from that difference in model flexibility and the chosen split position.

This does not tell the reviewer which representation is appropriate. If the step is an unwanted offset associated with a separately established change in acquisition conditions, removing it may answer a declared analysis question. If the step is the feature under investigation, the same operation can remove that feature from the residual. The numerical fit cannot decide between those interpretations on its own.

Do not infer continuity from a flat residual

The raw boundary difference remains ten in the saved input. The fitted segmented baseline also changes by ten at the boundary. A near-zero residual means raw minus fitted baseline is near zero; it does not mean the raw record or physical process was continuous.

The model keeps the raw vector unchanged and stores the fitted values separately. This makes the subtraction reviewable. A dashboard that displays only the residual would hide the information needed to distinguish a quiet original record from a model that exactly removed its discontinuity.

Treat the split as part of the method

Index 4 was deliberately selected in this constructed example to coincide with the step. It was not discovered by an automatic change detector, inferred from a maintenance log, or selected through a validated fault-classification procedure. The receipt identifies that choice explicitly.

A proposed robot signal review should retain the segmentation rule and the reason for each boundary alongside the output. Moving a boundary changes which samples share fitted parameters. The present fixture does not test alternative boundaries, unequal time spacing, missing samples, multiple channels, or an online implementation.

Keep the fit and interpretation in the same receipt

The saved replay records the raw values, sample indices, selected slices, two-column design convention, fitted coefficients, numerical ranks, residual vectors, RMS calculation, and unchanged-input check. Python 3.14.7 and NumPy 2.5.2 produced the local results. Separate source notes identify the SciPy reference as documentation only.

The practical lesson is to report what was subtracted. A smaller segmented residual can be completely explained by a baseline model that absorbs a step. Preserve the original signal and segmentation evidence so a reviewer can decide whether the removed component was unwanted drift or the very feature the analysis needed to retain.

Sources checked November 18, 2026:

SciPy, detrend reference, displayed as version 1.18.0:

https://docs.scipy.org/doc/scipy/reference/generated/scipy.signal.detrend.html

NumPy, numpy.linalg.lstsq reference, version 2.5 manual:

https://numpy.org/doc/stable/reference/generated/numpy.linalg.lstsq.html

The signal, matrix calculations, segmentation choice, and review proposal are original T-800 editorial work. No SciPy execution, real sensor measurement, fault diagnosis, or calibration result is claimed.

Illustration: an AI-generated concept shows a synthetic step absorbed by two fitted baselines. It is not a measured signal plot or a screenshot of an analysis application.