comparison m-toolbox/test/test_ao_index.m @ 0:f0afece42f48

Import.
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Wed, 23 Nov 2011 19:22:13 +0100
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:f0afece42f48
1 function test_ao_index()
2
3 % TEST_AO_INDEX tests the index() method of the AO class.
4 %
5 % M Hewitson 02-05-07
6 %
7 % $Id: test_ao_index.m,v 1.4 2008/09/19 14:03:50 ingo Exp $
8 %
9
10
11 a1 = ao(plist('tsfcn', 'randn(size(t))', 'fs', 100, 'nsecs', 10));
12 % Make a filter
13 f1 = miir(plist('type', 'highpass', 'fc', 20));
14
15
16 % Filter the input data
17 [a2, f1] = filter(a1, plist('filter', f1));
18
19
20
21 aos = cpsd([a1 a2]);
22
23 %% index output matrix of AOs
24
25 a11 = index(aos, 1,2)
26
27 % return
28 iplot(a11)
29 plot(a11.hist)
30
31
32 %% Save to .m file
33 type(a11, 'test.m');
34 % edit 'test.m'
35
36 %% Recreate from history
37
38 % now run it
39 mc
40
41 a1 = test()
42
43 iplot(a1)
44 plot(a1.hist)
45
46
47