Programs for visualization

From GHER

(Difference between revisions)
Jump to: navigation, search
(Color palettes)
(Image viewing)
 
(22 intermediate revisions not shown)
Line 1: Line 1:
-
A common question is which tools can be used to visualize the output of models and data analysis software.
+
The object of this page is to describe the tools can be used to visualize the output of models or data analysis software (DIVA, DINEOF)
-
* matlab produces figures of good quality in combination with '''m_map'''. But matlab is a proprietary software and expensive. '''m_map''' is available at [http://www.eos.ubc.ca/~rich/map.html http://www.eos.ubc.ca/~rich/map.html]
+
== Plotting tools ==
-
* [http://www.gnuplot.info/ gnuplot] is free software and available on numerous platforms. It supports many output formats, among others eps and png. However, some user find the figures of gnuplot not very pretty. To my knowledge, it cannot read NetCDF files directly.
+
Here is a list of tools able to generate images (vector or bitmap formats) using numerical information (generally ascii or binary files).
-
* [http://www.octave.org octave]: The scripting language is almost entirely compatible with matlab. In most cases, the code can run unchanged except for figures. But the downside, is that the visualization of octave is quite simple compared to matlab. It is based on gnuplot and has thus the same limitations that gnuplot. Octave can be extended using packages available at http://octave.sourceforge.net/. In particular you can add NetCDF support (octcdf). Installing octave from source is not trivial for novices. But pre-compiled packages of octave are available for most platforms. I recommend you to use the version 3.0.0 or later.
+
=== Programming languages ===
 +
 +
* [http://www.mathworks.com matlab] (proprietary software) produces figures of good quality in combination with the [http://www.eos.ubc.ca/~rich/map.html m_map] toolbox.
-
* python + [http://matplotlib.sourceforge.net/ matplotlib]. It doesn't aim to be compatible with matlab, but its syntax is quite close. The quality of graphics is excellent. A large number of add-ons is also available. For interactive use, ipython is very useful.
+
* [http://www.octave.org octave]: The scripting language is almost entirely compatible with matlab. In most cases, the code can run unchanged except for figures. But the downside is that the visualization of octave is quite simple compared to matlab. It is based on gnuplot and has thus the same limitations. Octave can be extended using packages available at http://octave.sourceforge.net/. In particular you can add NetCDF support ([http://octave.sourceforge.net/netcdf/index.html netcdf]). Installing octave from source is not trivial for novices. But pre-compiled packages of octave are available for most platforms. I recommend you to use the version 3.0.0 or later.
-
* [http://ferret.wrc.noaa.gov ferret] can read NetCDF files and has good visualization capabilities. It may take some time to understand the ferret language.  
+
* [http://www.python.org/ python] + [http://matplotlib.sourceforge.net/ matplotlib]. It doesn't aim to be compatible with matlab, but its syntax is quite close. The quality of graphics is excellent. A large number of add-ons is also available. For interactive use, ipython is very useful.
-
* [http://odv.awi.de/ ocean data view] is a graphical program that allows to visualize variables in various ways. It is not a programming environment like the previous ones and it thus easier to use for new users. However, it can also be used in scripts. It is free to use for research and educational purposes.
+
=== Software ===
-
== Color palettes ==
+
* [http://www.gnuplot.info/ gnuplot] is free software and available on numerous platforms. It supports many output formats, among others eps and png. However, some user find the figures of gnuplot not very pretty. To my knowledge, it cannot read NetCDF files directly.
-
Software like Matlab, Octova or Python already offer various color palettes. Here are some like to get more.
+
* [http://ferret.wrc.noaa.gov ferret] can read NetCDF files and has good visualization capabilities. It may take some time to understand the ferret language.  
 +
* [http://odv.awi.de/ Ocean Data View] is a graphical program that allows one to visualize variables in various ways. It is not a programming environment like the previous ones and it thus easier to use for new users. However, it can also be used in scripts. It is free to use for research and educational purposes.
-
* Data graphics research program: [http://geography.uoregon.edu/datagraphics/index.htm http://geography.uoregon.edu/datagraphics/index.htm]
+
=== Color palettes ===
 +
Software like Matlab, Octove or Python already offer various color palettes. Here are some like to get more.
 +
 +
* Data graphics research program: [http://geography.uoregon.edu/datagraphics/index.htm http://geography.uoregon.edu/datagraphics/index.htm]
* ColorBrewer: selecting schemes for maps: [http://www.personal.psu.edu/cab38/ColorBrewer/ColorBrewer.html http://www.personal.psu.edu/cab38/ColorBrewer/ColorBrewer.html]
* ColorBrewer: selecting schemes for maps: [http://www.personal.psu.edu/cab38/ColorBrewer/ColorBrewer.html http://www.personal.psu.edu/cab38/ColorBrewer/ColorBrewer.html]
Line 25: Line 31:
* MakeColorMap: matlab script for preparing colormaps: [http://www.mathworks.com/matlabcentral/fileexchange/17552 http://www.mathworks.com/matlabcentral/fileexchange/17552]
* MakeColorMap: matlab script for preparing colormaps: [http://www.mathworks.com/matlabcentral/fileexchange/17552 http://www.mathworks.com/matlabcentral/fileexchange/17552]
-
* cpt-city: archive of colormaps:  
+
* cpt-city: archive of colormaps: [http://soliton.vm.bytemark.co.uk/pub/cpt-city/ http://soliton.vm.bytemark.co.uk/pub/cpt-city/]
-
[http://soliton.vm.bytemark.co.uk/pub/cpt-city/ http://soliton.vm.bytemark.co.uk/pub/cpt-city/]
+
 
 +
== Drawing tools ==
 +
 
 +
Drawing tools are useful for creating diagrams, logos, or any image that is not based on a numerical file. They also can be employed to improve the images obtained with the plotting tools.
 +
 
 +
=== GIMP ===
 +
 
 +
[http://www.gimp.org/ GIMP] stands for GNU Image Manipulation Program. It can be used for many kinds of image editing.
 +
Here we describe a few examples of useful commands.
 +
 
 +
==== Creation of a rectangle with rounded corners ====
 +
 
 +
# Make a rectangle selection
 +
# Chose the option ''rounded corners''
 +
# Use Select -> To Path
 +
# Use Edit -> Stroke Selection and chose the thickness of the rectangle.
 +
'''Source:''' http://forums.macrumors.com/showthread.php?t=378936
 +
 
 +
==== Move a selection ====
 +
 +
Alt + Ctrl.
 +
'''Source:''' http://docs.gimp.org/nl/gimp-using-selections.html
 +
 
 +
==== Resize a selection ====
 +
 
 +
# Make a selection.
 +
# Select > Float (or Shift+Ctrl+L).
 +
# Select the ''Scale'' tool and drag the floating selection to resize it (or type numbers in the ''Scale'' dialogue box).
 +
# When you're happy with the result, just click the ''Anchor'' the floating layer button in the Layers Dialog.
 +
'''Source:''' http://ubuntuforums.org/showthread.php?t=989865
 +
 
 +
==== Draw arrows ====
 +
 
 +
Follow this link: http://maketecheasier.com/draw-arrows-in-gimp/2010/12/25
 +
 
 +
Save file '''arrow.scm''' in /home/username/.gimp-2.6/scripts/
 +
 
 +
==== Remove cables or other things ====
 +
 
 +
Use the '''clone''' tool.
 +
http://tech4tea.com/blog/2011/01/09/cloning-out-distractions-using-gimp-part-9-of-14/
 +
 
 +
=== Xfig ===
 +
 
 +
[http://epb.lbl.gov/xfig/ xfig] is a drawing tool that enables the user to easily create simple vector figures with latex formulas and text.
 +
Various output formats are available: eps, pdf, svg, and all the bitmap formats (png, tiff, jpg etc).
 +
 
 +
[[File:Xfig1.png|400px]]
 +
 
 +
=== TeXgraph ===
 +
 
 +
http://texgraph.tuxfamily.org/
 +
 
 +
== Image viewing ==
 +
 
 +
Here the objective is simply to display a set of images on the screen, without needing to click several times.
 +
 
 +
=== feh ===
 +
 
 +
[http://feh.finalrewind.org/ feh] is fast image viewer based on command line.
 +
 
 +
* To display the content of a directory (containing images):
 +
feh name_of_the_directory
 +
* display images in the first level subdirectories filtered by keyword in the filename (for example datestamp):
 +
feh */*<keyword>*.png
 +
* display images from all subdirectories filtered by keyword in the filename:
 +
find . -name "*<keyword>*" |xargs feh
 +
* position and resize the images within the fixed window size:
 +
find -g 950x950+970+0 <file_list>
 +
* ... many other useful features:
 +
man feh
 +
 
 +
 
 +
== Interactive maps ==
 +
 
 +
[[Leaflet]] is an open-source JavaScript library for mobile-friendly interactive maps.

Latest revision as of 12:56, 6 March 2017

The object of this page is to describe the tools can be used to visualize the output of models or data analysis software (DIVA, DINEOF)

Contents

Plotting tools

Here is a list of tools able to generate images (vector or bitmap formats) using numerical information (generally ascii or binary files).

Programming languages

  • matlab (proprietary software) produces figures of good quality in combination with the m_map toolbox.
  • octave: The scripting language is almost entirely compatible with matlab. In most cases, the code can run unchanged except for figures. But the downside is that the visualization of octave is quite simple compared to matlab. It is based on gnuplot and has thus the same limitations. Octave can be extended using packages available at http://octave.sourceforge.net/. In particular you can add NetCDF support (netcdf). Installing octave from source is not trivial for novices. But pre-compiled packages of octave are available for most platforms. I recommend you to use the version 3.0.0 or later.
  • python + matplotlib. It doesn't aim to be compatible with matlab, but its syntax is quite close. The quality of graphics is excellent. A large number of add-ons is also available. For interactive use, ipython is very useful.

Software

  • gnuplot is free software and available on numerous platforms. It supports many output formats, among others eps and png. However, some user find the figures of gnuplot not very pretty. To my knowledge, it cannot read NetCDF files directly.
  • ferret can read NetCDF files and has good visualization capabilities. It may take some time to understand the ferret language.
  • Ocean Data View is a graphical program that allows one to visualize variables in various ways. It is not a programming environment like the previous ones and it thus easier to use for new users. However, it can also be used in scripts. It is free to use for research and educational purposes.

Color palettes

Software like Matlab, Octove or Python already offer various color palettes. Here are some like to get more.

Drawing tools

Drawing tools are useful for creating diagrams, logos, or any image that is not based on a numerical file. They also can be employed to improve the images obtained with the plotting tools.

GIMP

GIMP stands for GNU Image Manipulation Program. It can be used for many kinds of image editing. Here we describe a few examples of useful commands.

Creation of a rectangle with rounded corners

  1. Make a rectangle selection
  2. Chose the option rounded corners
  3. Use Select -> To Path
  4. Use Edit -> Stroke Selection and chose the thickness of the rectangle.

Source: http://forums.macrumors.com/showthread.php?t=378936

Move a selection

Alt + Ctrl. 

Source: http://docs.gimp.org/nl/gimp-using-selections.html

Resize a selection

  1. Make a selection.
  2. Select > Float (or Shift+Ctrl+L).
  3. Select the Scale tool and drag the floating selection to resize it (or type numbers in the Scale dialogue box).
  4. When you're happy with the result, just click the Anchor the floating layer button in the Layers Dialog.

Source: http://ubuntuforums.org/showthread.php?t=989865

Draw arrows

Follow this link: http://maketecheasier.com/draw-arrows-in-gimp/2010/12/25

Save file arrow.scm in /home/username/.gimp-2.6/scripts/

Remove cables or other things

Use the clone tool. http://tech4tea.com/blog/2011/01/09/cloning-out-distractions-using-gimp-part-9-of-14/

Xfig

xfig is a drawing tool that enables the user to easily create simple vector figures with latex formulas and text. Various output formats are available: eps, pdf, svg, and all the bitmap formats (png, tiff, jpg etc).

TeXgraph

http://texgraph.tuxfamily.org/

Image viewing

Here the objective is simply to display a set of images on the screen, without needing to click several times.

feh

feh is fast image viewer based on command line.

  • To display the content of a directory (containing images):
feh name_of_the_directory
  • display images in the first level subdirectories filtered by keyword in the filename (for example datestamp):
feh */*<keyword>*.png
  • display images from all subdirectories filtered by keyword in the filename:
find . -name "*<keyword>*" |xargs feh
  • position and resize the images within the fixed window size:
find -g 950x950+970+0 <file_list>
  • ... many other useful features:
man feh


Interactive maps

Leaflet is an open-source JavaScript library for mobile-friendly interactive maps.

Personal tools