Next Previous Contents

4. Making plots

Each dataset holds a list of matrices. The position ( index ) on this list is called 'channel'. When making plot you'll have to import matrices and set them as the choosen channels in the current dataset. See also a further section 'Importing Data' in this mini-manual.

4.1 Curves

In this mode you can display any 2D curve Single data set consist of four matrices ( vectors ), which must have the same number of columns, and a one row:

 Channels:

   X-vector  ( optional - default vector is [0,1,2,3...] )
   Y-vector
   DX-vector ( optional - there is no default vector )
   DY-vector ( optional - there is no default vector )

Elements at corresponding positions in 'X-vector' and 'Y-vector' define coordinates of the succesive points. 'DX-vector' and 'DY-vector' are used to display vectors or error bars.

Example:

  Vectors xv = [1 3 4]; yv = [5 6 6]; represent lines from (1,5) to (3, 6) and from (3, 6) to (4, 2)

Although "curve" is the basic type of plot in this mode, you can display your data in different ways. Bars and samples are other types.

Using sheets

Algorithm is very simple

4.2 Vector Sets

To display a set of vectors you must provide all four vectors with the same size.

   X-vector
   Y-vector
   DX-vector
   DY-vector

Elements at corresponding positions in 'X-vector', 'Y-vector', 'DX-vector', 'DY-vector' define vectors.

Example:

 Vectors xv = [1 2]; yv = [4 5]; dx = [ 1 1 ]; dy = [0 2]
 represent two vectors. The first one at (1, 4) has value (1, 0),
 the second one placed at (2, 5) has value (1, 2).

Of course you must also set 'Vector' as plot type for this data set.

4.3 Images ( pixmaps )

Images plot accepts five matrices. In this mode you can handle efficiently large data sets.

    Red-Index-Gray, size: MxN,
    Green, size: MxN            ( optional - there is no default matrix )
    Blue,  size: MxN            ( optional - there is no default matrix )
    Column Index, size: 1x(N+1) ( optional - default vector is [0 1 2 ...] )
    Row Index, size: (M+1)x1    ( optional - default vectro is [0 1 2 ...] )

Matrix 'Red-Index-Gray' contains pixel values. Pixel at position (i,j) occupies a screen rectangle from Xmin=Column_index(i) to Xmax=Column_index(i+j) and from Ymin=Row_index(j) to Ymax=Row_index(j+1). Both vectors must be monotone. See example below.

Example:

                    5 3
   Red-Idnex-Gray = 4 5,  Column Index = [ 3 4 6 ], Row Index = [4 6 7],


                      3   4   6
                    4 +---|---+
                      |
                      | 5   3
                      |
       Image =      6 -   +   +
                      |
                      | 4   5
                      |
                    7 +---|---+

Note:

The V-Axis has a special role. Using it you can set a visible range of displayed values. Out of range values are clipped. All values below the minimum are displayed as black pixels and all values above maximum are displayed as white pixels. You can even set the log scale or turn on an autoscale on the V-axis. But before you change parameters of the V-axis remember to turn off 'Raw mode', which is enabled by default. 'Raw mode' means that matrix elements are not scaled - 0 always is displayed as a black pixel, and 255 is always displayed as a white pixel.

4.4 Surfaces

In this mode you can plot a 3d surface. It is optimized, so you can display efficiently large data sets. Surface plot accepts three matrices:

Channel 0: Surface values, size: MxN
Channel 1: Column index, size: 1xN ( optional - default vector is [0,1,2,...] )
Channel 2: Row index, size: Mx1 ( optional - default vector is [0;1;2;...] )

M and N can be any numbers, but the size of the second and the third channel depends on the size of a matrix at the first channel. 'Column index' nad 'Row index' must be monotone ( elements must be sorted )

Surface is the function z=f(x,y), where x and y form a rectangular grid and is calculated as follows:

 f( Column_index(col), Row_index(row) ) = Surface_values(row,col), where :
             row changes from 0 to M-1
             col changes from 0 to N-1

Example:

                    0 4 5                                        9

   surface_values = 4 5 6   Column_index = 3 4 9     Row_index = 3

                    3 5 7                                        1

are composed as follows:

           3 4 9

        9  0 4 5
        3  4 5 6
        1  3 5 7

4.5 Contours

Contour plots are similar to the 3d surface. Contour levels are defined by parameters of the v axis/grid.

4.6 Figures

In this mode you can plot any set of 3d polygons, but all of them must have the same number of vertices. Figure plots require three matrices, which must have the same size:

Facets - x coordinates
Facets - y coordinates
Facets - z coordinates

This works as explained below:

Number of columns defines a number of polygons. Values taken from one column of each matrix defines exactly one polygon. Number of rows is the same as number of vertices in each polygon.

For example those three (3,2) matrices:

      14      43       67
 fx = 25 fy = 56  fz = 45
      36      34       23

defines two triangles:

T1: p1=(1,4,6), p2=(2,5,4), p3=(3,3,2)
T2: p1=(4,3,7), p2=(5,6,5), p3=(6,4,3) 

There is also available mode using indexes to the table of points. See description of channels in File->Import Data dialog for further instructions.


Next Previous Contents