Source: disconnected_lines.f90
Line plots with gaps created by NaN separators.
Insert NaNs into your data arrays to break a line into separate segments.
disconnected_lines.f90 - Source codeoutput/example/fortran/disconnected_lines/make example ARGS="disconnected_lines"

ASCII output:
Disconnected Line Segments Example
+--------------------------------------------------------------------------------+
| |
| * o |
| |
| o - - - - o o Disconnected segments |
| * - - # Single point |
| 0.5 - |
| - - - |
| * - - o o |
| - |
| * - - |
| - - - |
| 0.0 |
| o o - |
| |
| - |
| * - |
| |
| -0.5 o # |
| - |
| - |
| * - |
| - |
| * * * * * * * * * * * * * o * * * * * * * * * * * * * * * * * * * * |
|0 1 2 3 4 5 6 7 8 |
+--------------------------------------------------------------------------------+
x
y