Vertical and horizontal spans

Source code Author Update time

using Plots
gaston()

vspan and hspan can be used to shade horizontal and vertical ranges.

hspan([1, 2, 3, 4]; label = "hspan", legend = :topleft)
vspan!([2, 3]; alpha = 0.5, label = "vspan")
plot!([0, 2, 3, 5], [-1, 3, 2, 6]; c = :black, lw = 2, label = "line")
Gnuplot Produced by GNUPLOT 5.4 patchlevel 2 0 2 4 6 0 1 2 3 4 5 hspan gnuplot_plot_2a vspan line hspan hspan gnuplot_plot_2a vspan vspan line line

This page was generated using DemoCards.jl and Literate.jl.