xbreak
xbreak(lo, hi)
Input: lo, hi · Output: no output
What it is
Reshapes the *main* x-axis's coordinate mapping with a fixed-width "//" jag that squeezes out the skipped range [lo, hi] (numbers, data units) — linear-scale axes only. Not a sub-panel (unlike zoom_inset).
Overloads
One call shape — this function is not overloaded.
| Code | Input | Output | Description |
xbreak(lo, hi) | lo numbernot documented yethi numbernot documented yet | no output | Not a sub-panel (unlike zoom_inset). |
Examples
From the documentation, and run by the build -- the output and the figure below are what the engine actually produced. Simplest first.
t = linspace(0, 1, 200)
y = sin(2 * pi * 5 * t)
plot(t, y)
xspan(0.2, 0.4, color = "orange")
yspan(-0.3, 0.3, color = "green")
arrow(0.6, 0, 0.8, 0.8)
arrowtext(0.85, -0.5, 0.95, 0.2, "peak")
figure()
plot(t, t)
xbreak(0.3, 0.6)
figure()
plot(t, t)
ybreak(0.3, 0.6)
figure()
plot(t, y)
blur_backdrop(0.2, 0.2, 0.8, 0.8, radius = 4)
print(tex([1, 2; 3, 4]))
printtex([1, 2; 3, 4])
· plot: figure 39 (200 points)
· plot: figure 40 (200 points)
· plot: figure 41 (200 points)
· plot: figure 42 (200 points)
$\begin{bmatrix} 1 & 2 \\ 3 & 4 \end{bmatrix}$
$\begin{bmatrix} 1 & 2 \\ 3 & 4 \end{bmatrix}$from plotting
How it works
xbreak(lo, hi)/ybreak(lo, hi) — a sibling of zoom_inset, not the same feature: this reshapes the *main* axis's own coordinate mapping (a fixed-width "//" jag squeezes the skipped (lo, hi) range instead of giving it pixel space proportional to its span), it doesn't add a sub-panel. See plotting::Panel.x_break's doc comment for the linear-scale- only scope limit.
From the note above this builtin in the interpreter, where the reasoning was written down as it was built.