view m-toolbox/test/test_split_chunks.m @ 47:dd93c9ba6624 database-connection-manager

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

% function a_out = test_ao_split_chunks
% Test AO split.
% 
% M Hewitson 23-02-08
% 
% $Id: test_split_chunks.m,v 1.1 2008/02/23 16:34:19 hewitson Exp $
% 

% Test AO

a1 = ao(plist('tsfcn', 'sin(2*pi*0.1*t)', 'nsecs', 100, 'fs', 10));

% Split into chunks
as = split(a1, plist('split_type', 'chunks', 'N', 10));

% Plot chunks
iplot(as, plist('Markers', {'All', 'o'}))

b = join(as);
figure
plot(b.hist);

iplot(a1, b)
iplot(a1./b);

return

%% Recreate from history

% Write an m-file from AO
ao2m(b, 'ltpda_test.m');

% now run it
clear all
a_out = ltpda_test;

iplot(a_out)
figure
plot(a_out.hist)

%% Delete test files
% delete('ltpda_test.m');