view m-toolbox/test/test_ao_1.m @ 46:ca0b8d4dcdb6 database-connection-manager

Fix
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Tue, 06 Dec 2011 19:07:27 +0100
parents f0afece42f48
children
line wrap: on
line source

% Test functionality of analysis objects.
%
%
% M Hewitson 01-02-07
%
% $Id: test_ao_1.m,v 1.24 2009/02/02 15:20:39 hewitson Exp $
%
function test_ao_1()
  
  % Make test AOs
  
  nsecs = 10;
  fs    = 1000;
  
  pl = plist('nsecs', nsecs, 'fs', fs, 'tsfcn', 'randn(size(t))');
  
  a1 = ao(pl);
  a2 = ao(pl);
  a3 = ao(pl);
  
  % Add the two analysis objects
  
  a4 = a3+a2;
  a5 = a4+a1;
  
  %% Plot both
  
  plot(a5.hist);
  
  % Rebuid
  a_out = a5.rebuild;
  
  iplot(a_out)
  plot(a_out.hist)
  
end