0
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
1 <!-- $Id: ao_plot_content.html,v 1.5 2009/09/29 22:27:12 ingo Exp $ -->
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
2 <p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
3 The data in an AO can be plotted using the <tt>iplot</tt> method.
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
4 </p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
5 <p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
6 The <tt>iplot</tt> method provides an advanced plotting interface for AOs which tries to make good use of all the information
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
7 contained within the input AOs. For example, if the <tt>xunits</tt> and <tt>yunits</tt> fields of the input AOs are set, these labels
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
8 are used on the plot labels.
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
9 </p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
10
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
11 <p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
12 In addition, <tt>iplot</tt> can be configured using a input <tt>plist</tt>. The following examples show some of the
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
13 possible ways to use <tt>iplot</tt>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
14 </p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
15
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
16 <div class="fragment"><pre>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
17 >> a1 = ao(plist(<span class="string">'tsfcn'</span>, <span class="string">'sin(2*pi*0.3*t) + randn(size(t))'</span>, <span class="string">'fs'</span>, 10, <span class="string">'nsecs'</span>, 20))
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
18 ----------- ao 01: a1 -----------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
19
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
20 name: None
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
21 data: (0,0.887479404587351) (0.1,-0.449797172615395) (0.2,0.479022102390939) ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
22 -------- tsdata 01 ------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
23
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
24 fs: 10
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
25 x: [200 1], double
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
26 y: [200 1], double
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
27 dx: [0 0], double
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
28 dy: [0 0], double
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
29 xunits: [s]
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
30 yunits: []
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
31 nsecs: 20
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
32 t0: 1970-01-01 00:00:00.000
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
33 -------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
34
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
35 hist: ao / ao / SId: fromTSfcn ... $-->$Id: ao ... S
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
36 mdlfile: empty
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
37 description:
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
38 UUID: 67d31c2f-8ee5-42ba-a96b-cfb288ecc9ea
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
39 ---------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
40
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
41 >> a1.data
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
42 -------- tsdata 01 ------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
43
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
44 fs: 10
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
45 x: [200 1], double
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
46 y: [200 1], double
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
47 dx: [0 0], double
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
48 dy: [0 0], double
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
49 xunits: [s]
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
50 yunits: []
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
51 nsecs: 20
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
52 t0: 1970-01-01 00:00:00.000
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
53 -------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
54 </pre></div>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
55 <p> Creates a time-series AO. If we look at the data object contained in this AO, we see that the <tt>xunits</tt>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
56 are set to the defaults of seconds [s].</p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
57 <p>If we plot this object with <tt>iplot</tt> we see these units reflected in the x and y axis labels.</p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
58 <div class="fragment"><pre>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
59 >> iplot(a1)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
60 </pre></div>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
61
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
62 <img src="images/ao_iplot_eg1.png" alt="AO iplot eg1" border="3" width="600px">
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
63
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
64 <p>We also see that the time-origin of the data (<tt>t0</tt> field of the <tt>tsdata</tt> class) is displayed as the plot title.</p>
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
65
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
66
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
67
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
68
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
69
|