Home > classes > @tsdata > reshapeT.m

reshapeT

PURPOSE ^

RESHAPET reshape the time-vector to match the x vector.

SYNOPSIS ^

function ts = reshapeT(ts, varargin)

DESCRIPTION ^

 RESHAPET reshape the time-vector to match the x vector.

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

 DESCRIPTION: RESHAPET reshape the time-vector to match the x vector.

 CALL:        tsdata = reshape(tsdata)

 VERSION:     $Id: reshapeT.m,v 1.4 2007/11/30 19:36:05 ingo Exp $

 HISTORY:     31-01-2007 M Hewitson
                 Creation

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

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function ts = reshapeT(ts, varargin)
0002 % RESHAPET reshape the time-vector to match the x vector.
0003 %
0004 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0005 %
0006 % DESCRIPTION: RESHAPET reshape the time-vector to match the x vector.
0007 %
0008 % CALL:        tsdata = reshape(tsdata)
0009 %
0010 % VERSION:     $Id: reshapeT.m,v 1.4 2007/11/30 19:36:05 ingo Exp $
0011 %
0012 % HISTORY:     31-01-2007 M Hewitson
0013 %                 Creation
0014 %
0015 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0016 
0017 VERSION  = '$Id: reshapeT.m,v 1.4 2007/11/30 19:36:05 ingo Exp $';
0018 
0019 if  nargin == 2 && isa(ts, 'tsdata') && ischar(varargin{1})
0020   if strcmp(varargin{1}, 'Params')
0021     ts = plist();
0022     return
0023   elseif strcmp(varargin{1}, 'Version')
0024     ts = VERSION;
0025     return
0026   end
0027 end
0028 
0029 if size(ts.x, 1) ~= size(ts.y,1)
0030   ts.x = [ts.x].';
0031 end
0032 
0033 % END

Generated on Tue 22-Jan-2008 10:39:13 by m2html © 2003