manpagez: man pages & more
info gnuplot
Home | html | info | man
[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

3.14.2.2 binary general

General binary data in which format information is not necessarily part of the file can be read by giving further details about the file format at the command line. Although the syntax is slightly arcane to the casual user, general binary is particularly useful for application programs using gnuplot and sending large amounts of data.

Syntax:

      plot '<file_name>' {binary <binary list>} ...
      splot '<file_name>' {binary <binary list>} ...

General binary format is activated by keywords in <binary list> pertaining to information about file structure, i.e., array, record, ‘format‘ or filetype. Otherwise, matrix binary format is assumed. (See ‘binary matrix‘ for more details.)

There are some standard file types that may be read for which details about the binary format may be extracted automatically. (Type ‘show datafile binary‘ at the command line for a list.) Otherwise, details must be specified at the command line or set in the defaults. Keywords are described below.

The keyword filetype in <binary list> controls the routine used to read the file, i.e., the format of the data. For a list of the supported file types, type ‘show datafile binary filetypes‘. If no file type is given, the rule is that traditional gnuplot binary is assumed for ‘splot‘ if the ‘binary‘ keyword stands alone. In all other circumstances, for ‘plot‘ or when one of the <binary list> keywords appears, a raw binary file is assumed whereby the keywords specify the binary format.

General binary data files fall into two basic classes, and some files may be of both classes depending upon how they are treated. There is that class for which uniform sampling is assumed and point coordinates must be generated. This is the class for which full control via the <binary list> keywords applies. For this class, the settings precedence is that command line parameters override in-file parameters, which override default settings. The other class is that set of files for which coordinate information is contained within the file or there is possibly a non-uniform sampling such as gnuplot binary.

Other than for the unique data files such as gnuplot binary, one should think of binary data as conceptually the same as ASCII data. Each point has columns of information which are selected via the ‘<using list>‘ associated with using. When no ‘format‘ string is specified, gnuplot will retrieve a number of binary variables equal to the largest column given in the ‘<using list>‘. For example, ‘using 1:3‘ will result in three columns being read, of which the second will be ignored. There are default using lists based upon the typical number of parameters associated with a certain plot type. For example, ‘with image‘ has a default of ‘using 1‘, while rgbimage has a default of ‘using 1:2:3‘. Note that the special characters for using representing point/line/index generally should not be used for binary data. There are keywords in <binary list> that control this.


[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

This document was generated on November 19, 2011 using texi2html 5.0.