File: scaleunits.html

package info (click to toggle)
ploticus 2.0.3-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 3,696 kB
  • ctags: 2,035
  • sloc: ansic: 40,100; perl: 456; sh: 186; makefile: 129
file content (251 lines) | stat: -rw-r--r-- 7,693 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
<html>
<head>
<!-- This file has been generated by unroff 1.0, 03/04/02 13:26:19. -->
<!-- Do not edit! -->
<STYLE TYPE="text/css">
<!--
        A:link{text-decoration:none}
        A:visited{text-decoration:none}
        A:active{text-decoration:none}
-->
</STYLE>
<title>ploticus: scale units</title>
<body bgcolor=D0D0EE vlink=0000FF>
<br>
<br>
<center>
<table cellpadding=2 bgcolor=FFFFFF width=550 ><tr>
<td>
  <table cellpadding=2 width=550><tr>
  <td><br><h2>scale units</h2></td>
  <td align=right>
  <small>
  <a href="../doc/Welcome.html"><img src="../doc/ploticus.gif" border=0></a><br>
  <a href="../doc/Welcome.html">Welcome</a> &nbsp; &nbsp;
  <a href="../gallery/index.html">Gallery</a> &nbsp; &nbsp;
  <a href="../doc/Contents.html">Handbook</a> 
  <td></tr></table>
</td></tr>
<td>
<br>
<br>

<title>Manual page for scale_units(PL)</title>
</head>
<body>


<h2>DESCRIPTION</h2>
A number of types of scaling units may be
used when plotting data.  They are described here.<tt> </tt>


<h2>EXAMPLES</h2>
A number of examples illustrating the various scale types 
may be veiwed from the 
Gallery Scaling and Axes page
<a href="../gallery/gall.sa.html"><img src="../gallery/btn/here.gif"></a>


<h2>ABSOLUTE UNITS</h2>
<b>Absolute</b> units are not used for plotting data 
but rather for defining plot areas and for purposes
such as placing annotation, etc.  
Absolute space is measured in inches (or centimeters if
set in the config file, proc settings, or using the <tt>-cm</tt> command line 
option).  The origin (0,0) is always at 
the <b>lower-left</b> corner.<tt> </tt>

<br><br><br>

<h2>DATA SCALING UNITS</h2>
A number of scaling units are available.<tt> </tt>
Scaling is set in <b>proc areadef</b> or in <b>proc defineunits</b>.<tt> </tt>
<p>
The following are the available types of scaling.<tt> </tt>
For each type a description is given.  Each type also
has one or more display format specifications,
which determine how incremental stubs will be presented.<tt> </tt>

<br><br><br>

<h2>LINEAR</h2>
<p>
Standard linear numeric scale.<tt> </tt>
Numeric values may be any mixture of integer or floating point
(exponential/scientific notation e.g. 4.336e11 is supported).<tt> </tt>
Linear scaling is used for plotting continuous numeric data;
it may also be used with series, such as bars when no
location value is present in the data, or lineplots
when no X value is present in the data.<tt> </tt>
<p>
<b>Display format</b>:
Display of numerics
is controlled using a 
<a href="attributetypes.html#printfspec">
 printf-spec
</a>

<br><br><br>

<h2>LOG</h2>
<p>
Logarithmic numeric scale.<tt> </tt>
Numeric values may be any mixture of integer or floating point
(exponential/scientific notation is supported).<tt> </tt>
The log of 0.0 or of negative numbers is nonexistant;
therefore log plots should have a minima &gt; 0 (very small
numbers such as 0.01 are OK).<tt> </tt>
<p>
Also available is <b>log+1</b> scaling, which is similar to <b>log</b>
but uses <tt>log( value+1 )</tt>.  This is useful for log-characteristic data 
that can include values at or near 0.0.<tt> </tt>
<p>
If using log scaling along with autorange, and if values
of 0.0 are found, log+1 scaling will automatically be used.<tt> </tt>
<p>
<b>Display format</b> - same as linear, above.<tt> </tt>
<p>
The proc axis <tt>stubcull</tt> attribute may be useful in eliminating "stub pile-up"
when rendering log axes.<tt> </tt>

<br><br><br>

<a name=categories></a>

<h2>CATEGORIES</h2>
<p>
Positioning by category.  
This scaling method differs from the others in that it does not
use a continuous scale.<tt> </tt>
It is useful in positioning bars, rangebars, 1-D scatterplots or 
symbols based on a value or category.<tt> </tt>
Values are considered labels and may be anything-- they may even contain
embedded spaces and <tt>\n</tt>.  No <b>proc areadef</b> range is specified; instead,
the categories are specified in an areadef <tt>xcategories</tt> or
<tt>ycategories</tt> attribute.<tt> </tt>
Data are categorized by comparing with all category labels
until a match is found.<tt> </tt>
The details of how this comparison is actually done can be controlled using areadef
attribute <tt>catcompmethod</tt>.<tt> </tt>
<p>
<b>Display format</b> - the defined category names.<tt> </tt>

<br><br><br>

<h2>DATE</h2>
<p>
Allows date information to be plotted directly.  A number of
<a href="dates.html">
 date notations
</a>
(including year/month and quarter year notations)
are supported for plotting and date arithmetic.<tt> </tt>
It is possible to omit weekends if desired - see
<a href="settings.html">
 proc settings.<tt> </tt>
</a>

<p>
<b>Display format</b>: Dates may be displayed in
any of the supported date arithmetic formats,
or in a number of additional 
<a href="dates.html#display">
 display formats
</a>
<p>
The basic date unit is always a <b>day</b>, regardless
of which notation is in use.  Stub and tic increments
may be expressed in <tt>months</tt> or <tt>years</tt>, if desired.<tt> </tt>


<br><br><br>

<h2>TIME</h2>
<p>
Allows date information to be plotted directly.  Several 
<a href="times.html">
 time notations
</a>
are supported for plotting and time arithmetic.<tt> </tt>
<p>
<b>Display format</b>: Times may be displayed in any of
the supported time arithmetic formats.<tt> </tt>
<p>
The basic time unit is a <b>minute</b>.<tt> </tt>

<br><br><br>
<a name=datetime></a>

<h2>DATETIME</h2>
<p>
Allows time information to be plotted across multiple days.<tt> </tt>
A datetime data field should have the format <i>date</i>.<i>time</i>
(i.e. the date and time are connected using a dot).  
If your data has the date and time in two separate fields,
the proc getdata <tt>filter</tt> attribute may be used to
connect them with a dot.<tt> </tt>
<p>
The date and time formats may be any of those supported for
plotting and arithmetic.<tt> </tt>
For example, if your datetime fields are like this:
<tt>22Aug1999.16:44</tt> you would specify the datetime
format as <tt>ddMmmyyyy.hh:mm</tt>.<tt> </tt>
<p>
<b>Display format</b>: Same as above, except that the date
component or the time component may be omitted if desired.<tt> </tt>
<p>
The basic datetime unit is a <b>day</b>.<tt> </tt>
<p>
An example of datetime scaling is in 
<a href="../gallery/hitcount.htm">
 hitcount
</a>

<br><br><br>

<h2>DATETIME WITH TIME WINDOWING</h2>
<p>
Sometimes it is desirable to show only portions of each day, when showing
the entire 24 hour day would be too much. Examples of this include a work
day or a trading day. <b>datetime</b> scaling allows you to do this- you can
indicate the time range for each day at the end of the datetime keyword.<tt> </tt>
For example:
<dl>
<dt><dd><p>
<tt>datetime9-17</tt> 
<br>
would show only the hours from 9:00 to 17:00 for each day.  
</dl>
<p>
<b>Rules:</b> Only whole hours may be used in the time window definition.<tt> </tt>
Time values that are outside the
defined time window will be displayed at the time window boundary and a warning will be 
issued.  The areadef range must contain time components that are within the
time window range.  Incremental axis labels in day units may be used, but hour units 
may not be used.<tt> </tt>
<p>
An example of datetime scaling with time window is in
<a href="../gallery/hitcount3.htm">
 hitcount3
</a>


<br>
<br>
</td></tr>
<td align=right>
<a href="../doc/Welcome.html">
<img src="../doc/ploticus.gif" border=0></a><br><small>data display engine &nbsp; <br>
<a href="../doc/Copyright.html">Copyright Steve Grubb</a>
<br>
<br>
<center>
<img src="../gallery/all.gif">
</center>
</td></tr>
</table>
<p><hr>
Markup created by <em>unroff</em> 1.0,&#160;<tt> </tt>&#160;<tt> </tt>March 04, 2002.
</body>
</html>