Source: fill_between_demo.f90
Create filled regions using both the stateful API and figure_t.
The demo highlights part of an oscillatory curve and shades a baseline response.
Generated files are written to output/example/fortran/fill_between_demo/ in
both PNG and ASCII formats.
fill_between_demo.f90 - Source codeoutput/example/fortran/fill_between_demo/make example ARGS="fill_between_demo"

ASCII output:
Object API fill_between baseline
+--------------------------------------------------------------------------------+
| 0.8 |
| |
| | |
| 0.6 |
| |
| | |
| 0.4 |
| |
| | ---------------- |
| -----+++++++++++++++----- |
| 0.2 ---++++++++++++++++++++++++---- |
| ----+++++++++++++++++++++++++++++++--- |
| | ---+++++++++++++++++++++++++++++++++++++--- |
| 0.0-++++++++++++++++++++++++++++++++++++++++++--- |
| -++++++++++++++++++++++++++++++++++++++++++++++++---++++++++++++++++++++++++++ |
| ----++++++++++++++++++++++ |
| | ----++++++++++++++++++ |
| -0.2 -----+++++++++++++ |
| -------------- |
| | |
| -0.4 |
| |
| | - - - - - - - - - - - - - - - - - - - - - - - - |
| 0.0 0.8 1.6 2.4 3.2 4.0 4.8 5.6 |
+--------------------------------------------------------------------------------+
time
response

ASCII output:
Stateful fill_between with mask
+--------------------------------------------------------------------------------+
| |
| | |
| 0.8 |
| -- sin(x) |
| | |
| 0.5 |
| |
| | -------------- |
| 0.2 ----++++++++++++----- |
| | ---++++++++++++++++++++---- |
| ---++++++++++ +++++++++--- |
| 0.0-++++ ++++--- |
| |-+ +--- --- |
| --- --- |
| -0.2 --- --- |
| | ---- --- |
| ----- ---- |
| | -------------- |
| -0.5 |
| |
| | |
| -0.8 |
| | - - - - - - - - - - - - - - - - - - - - - - - - - - |
| 0.0 0.8 1.6 2.4 3.2 4.0 4.8 5.6 |
+--------------------------------------------------------------------------------+
angle (rad)
amplitude