Annotation Demo

Annotation Demo

Source: annotation_demo.f90

Add text annotations in data coordinates.

Files

  • annotation_demo.f90 - Source code
  • Generated media in output/example/fortran/annotation_demo/

Running

make example ARGS="annotation_demo"

Output

Annotation Demo

annotation_demo.png

ASCII output:

                     Scientific Data with Text Annotations
+--------------------------------------------------------------------------------+
|                                                                                |
| |                                                                              |
| 0.6                                                                            |
|                                             -- Damped sine: sin(x)e^-x/4       |
|                                             -- Exponential: e^-x - 0.5         |
| 0.5                                         -- Quadratic: 0.1(x-3)^2 - 0.3   \ |
|                                                                                |
| |                                                                              |
|                                                                                |
| 0.3            ****                                                            |
| #         *****  . *****                                                     # |
| ##      ***             ***                                       Peak Region  |
| | ##  **                   **                                            ##    |
| 0.2 #%%                      ***                                      ###      |
|    ** ###                      ***                                  ###        |
|   **%    ##                       **                              ##           |
| 0.0  %%    ###                      ***                        ###             |
| *      %%%   ####                     ***                   ####               |
| |         %%     ####                    ***            ####              **** |
|             %%%v     ####                   ***     ####              ****     |
| -0.2           %%%%%     #########         ####%%%%%           *******         |
|                     %%%%%%%       #########         ***********                |
|                            %%%%%%%%%%%%%%%%                                    |
| |                                          %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
| -0.3                                                                           |
|                                                                                |
|                                                                                |
| -0.5                                                                           |
| |  -  -  -  -  -  -  -  -  -  -  -  -   -  -  -  -  -  -  -  -  -  -  -  -   - |
| 0.0      0.8        1.6       2.4        3.2       4.0       4.8        5.6    |
+--------------------------------------------------------------------------------+
                            Independent Variable (x)
Dependent Variable (y)

Download ASCII

Download PDF