Home > classes > @fsdata > set_xy_axis.m

set_xy_axis

PURPOSE ^

SET_XY_AXIS set the x-axis and y-axis values.

SYNOPSIS ^

function data_out = set_xy_axis(data, x, y)

DESCRIPTION ^

 SET_XY_AXIS set the x-axis and y-axis values.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

 DESCRIPTION: SET_XY_AXIS set the x-axis and y-axis values.

 CALL:       data = set_xy_axis (data,    x, y);
          ao.data = set_xy_axis (ao.data, x, y);

 VERSION: $Id: set_xy_axis.html,v 1.13 2008/03/31 10:27:36 hewitson Exp $

 HISTORY: 21-06-2007 Diepholz
             Creation

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function data_out = set_xy_axis(data, x, y)
0002 % SET_XY_AXIS set the x-axis and y-axis values.
0003 %
0004 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0005 %
0006 % DESCRIPTION: SET_XY_AXIS set the x-axis and y-axis values.
0007 %
0008 % CALL:       data = set_xy_axis (data,    x, y);
0009 %          ao.data = set_xy_axis (ao.data, x, y);
0010 %
0011 % VERSION: $Id: set_xy_axis.html,v 1.13 2008/03/31 10:27:36 hewitson Exp $
0012 %
0013 % HISTORY: 21-06-2007 Diepholz
0014 %             Creation
0015 %
0016 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0017 
0018 VERSION  = '$Id: set_xy_axis.html,v 1.13 2008/03/31 10:27:36 hewitson Exp $';
0019 CATEGORY = 'Internal';
0020 
0021 % Check if this is a call for parameters
0022 if nargin == 2
0023   if isa(data, 'fsdata') && ischar(x)
0024     in = char(x);
0025     if strcmp(in, 'Params')
0026       data_out = plist;
0027       return
0028     elseif strcmp(in, 'Version')
0029       data_out = VERSION;
0030       return
0031     elseif strcmp(in, 'Category')
0032       data_out = CATEGORY;
0033       return
0034     end
0035   end
0036 end
0037 
0038 if nargin ~= 3
0039   error (['### please call this function with three parameter: ' ...
0040     'data = set_xy_axis (data, x, y);']);
0041 end
0042 
0043 if size(x,2) > size(x,1)
0044   x = x.';
0045 end
0046 if size(y,2) > size(y,1)
0047   y = y.';
0048 end
0049 
0050 data_out    = data;
0051 data_out.x  = x;
0052 data_out.y  = y;
0053 
0054 if nargin == 0
0055   error('### please use: data = set_xy_axis (data, x, y);');
0056 end
0057 
0058 % END

Generated on Mon 31-Mar-2008 12:20:24 by m2html © 2003