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 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315
|
<html>
<head>
<!-- This file has been generated by unroff 1.0, 03/01/02 13:44:43. -->
<!-- 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: dates</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>Dates</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>
<a href="../gallery/index.html">Gallery</a>
<a href="../doc/Contents.html">Handbook</a>
<td></tr></table>
</td></tr>
<td>
<br>
<br>
<title>Manual page for Dates(PL)</title>
</head>
<body>
<h2>Ploticus date processing</h2>
Ploticus can plot dates directly and do date arithmetic.<tt> </tt>
Many details of date processing, including localization of month and weekday names,
can be controlled via settings in
<a href="settings.html">
proc settings
</a>
or in your
<a href="config.html">
config file.<tt> </tt>
</a>
There are also a number of
<a href="functions.html">
functions
</a>
that deal with dates.<tt> </tt>
<br><br><br>
<h2>Plottable date notations</h2>
The following date notations are supported for plotting and date arithmetic:
<p>
<b>Month, day, and year notations:</b>
<ul>
<li>
<tt>mmddyy</tt> (example: 033199)
<li>
<tt>mm-dd-yy</tt> (example: 03-31-99)
<li>
<tt>mm-dd-yyyy</tt> (example: 03-31-1999)
<li>
<tt>mm/dd/yy</tt> (example: 03/31/99)
<li>
<tt>dd-mm-yy</tt> (example: 31-03-99)
<li>
<tt>dd/mm/yyyy</tt> (example: 31/03/99)
<li>
<tt>ddmmmyyyy</tt> (example: 31mar1999 or 31MAR99)
<li>
<tt>dd-mmm-yy</tt> (example: 31-mar-99 or 31-MAR-99)
<li>
Others:
<pre>
mm/dd/yyyy mmddyyyy mm.dd.yy mm.dd.yyyy
mmm-dd-yy mmm-dd-yyyy mmm_dd_yy mmm_dd_yyyy
mmm/dd/yy mmm/dd/yyyy
dd-mm-yy dd-mm-yyyy dd/mm/yy dd/mm/yyyy
ddmmyy dd.mm.yy dd.mm.yyyy
dd-mmm-yyyy dd_mmm_yy dd_mmm_yyyy
dd/mmm/yy dd/mmm/yyyy ddmmmyy ddmmmyyyy
yy-mm-dd yy/mm/dd yymmdd yy.mm.dd
yyyy-mm-dd yyyy/mm/dd yyyymmdd yyyy.mm.dd
yyyy-mmm-dd yyyy_mmm_dd yyyymmmdd
</pre>
<tt></tt></ul>
<p>
<b>Month & year notations</b>
<br>
(a day value of 01 is used internally for arithmetic/plotting purposes):
<ul>
<li>
<tt>yymm</tt> (example: 9903)
<li>
<tt>mm/yyyy</tt> (example: 03/1999)
<li>
Others: <tt>
yy/mm yy-mm yyyymm yyyy/mm yyyy-mm
mm/yy mm-yy mm-yyyy</tt>
</ul>
<p>
<b>Quarter year notations</b>
<br>
(day and month will be set to mid-quarter for arithmetic/plotting purposes):
<ul>
<li>
<tt>yyqn</tt> (example: 99q1 or 99Q1)
<li>
<tt>nqyyyy</tt> (example: 1q1999 or 1Q1999)
<li>
Others:
<tt>yyyyqn nqyy </tt>
</ul>
<p>
<b>Year only notation</b>
<ul>
<li>
<tt>yy</tt> (uses pivot year, so 00 is greater than 99)
<br><br><br>
</ul>
<h2>Basic unit</h2>
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>Setting date notation</h2>
Any date value to be plotted or involved in date arithmetic must
conform to the current date notation.<tt> </tt>
The default notation is <b>mmddyy</b>.<tt> </tt>
The date notation can be set using the
<tt>xscaletype</tt> or <tt>yscaletype</tt> attributes of
<a href="areadef.html">
proc areadef
</a>
( or
<a href="defineunits.html">
proc defineunits
</a>
), or using
<a href="settings.html">
proc settings
</a>
, by using a
<a href="config.html">
config file.<tt> </tt>
</a>
<a name=display></a>
<h2>Display-only notations</h2>
In addition to the above plottable notations,
the following additional notations may be used only for
displaying dates (such as with the stubformat
attribute, for instance). They may not be used for
date plotting or arithmetic.<tt> </tt>
<p>
<b>Full dates for presentation:</b>
<ul>
<li>
<tt>month_dd,_yyyy </tt>(or <tt>full</tt>) (example: March 31, 1999)
<li>
<tt>mon_dd,_yyyy</tt> (example: Mar 31, 1999)
<li>
<tt>dd_month,_yyyy</tt> (example: 31 March, 1999)
<li>
<tt>dd_mon,_yyyy</tt> (example: 31 Mar, 1999)
<li>
<tt>Www_dd_mon,_yyyy </tt>(or <tt>wfull</tt>) (example: Wed 31 Mar, 1999)
</ul>
<p>
<b>Month & year only:</b> <tt>mmyy, mmyyyy</tt>
<p>
<b>Month & day only:</b> <tt>mmmdd, mmm/dd, mmm-dd, mmm_dd, mm/dd, mm-dd, mm_dd
</tt><p>
<b>Year only:</b> <tt>'yy, yyyy</tt>
<p>
<b>Month only:</b> <tt>mmm, mm, m</tt>
<p>
<b>Day only:</b> <tt>dd d</tt>
<p>
<b>Weekday:</b>
<ul>
<li>
<tt>W</tt> (example: S M T W T F S)
<li>
<tt>Www</tt> (example: Sun Mon Tue Wed Thu Fri Sat)
<br><br><br>
</ul>
<h2>Key to notation codes</h2>
<br>
<tt>m</tt> = single character month (use M for capitalized)
<br>
<tt>mm</tt> = numeric month 01-12
<br>
<tt>mmm</tt> = three-character month e.g. jan (use MMM for JAN or Mmm for Jan)
<br>
<tt>mon</tt> = month abbreviation e.g. Jan
<br>
<tt>month</tt> = full month e.g. January
<br>
<tt>dd</tt> = numeric day 01-31
<br>
<tt>d</tt> = numeric day 1-31
<br>
<tt>yy</tt> = numeric year 00-99
<br>
<tt>yyyy</tt> = numeric year 1800-up
<br>
<tt>w</tt> = single character weekday (use W for capitalized)
<br>
<tt>www</tt> = three character weekday (use Www or WWW for capitalized)
<br>
<tt>n</tt> = 1, 2, 3 or 4 (quarter year notations)
<br>
<tt>q</tt> = the letter <tt>q</tt> or <tt>Q</tt> (quarter year notations)
<br>
<tt>_</tt> (underscore) = space
<br><br><br>
<h2>Notes</h2>
<p>
1. It is possible to omit weekends. This is usually done
in business- or market-related plots. To omit weekends,
set the <tt>omitweekends</tt> attribute in
<a href="settings.html">
proc settings
</a>
<p>
2. Conversion from two-digit dates to four digit dates is
achieved using a pivot year- any two digit year less than
this value is assumed to be 21st century.
The default pivot year is <b>77</b>.<tt> </tt>
<p>
3. When three-character months are used, they are always
entered and stored as lower case; however the capitalization
of the "mmm" can be altered to control the way dates are
presented, e.g. Mmm = Jan, MMM = JAN.<tt> </tt>
<p>
4. "Lazy" dates may be used.<tt> </tt>
A lazy date has 00 as the day and/or month portion and is usually
used in situations where the day and/or month is unknown or unavailable.<tt> </tt>
When a lazy date is used in date arithmetic the
missing month and/or day is converted to 01.<tt> </tt>
By default, lazy dates are not permitted for date arithmetic.<tt> </tt>
<p>
5. When using notations that do not contain a specific day
(such as month year, quarter year, or year only)
there may be occasions when it is necessary to specify an
exact day point (for example to create an annotation).<tt> </tt>
To do this, an alternate full date format may be used.<tt> </tt>
For example, if <tt>yyqn</tt> notation is being used,
full dates may be given in <tt>yy/mm/dd</tt> format.<tt> </tt>
For an example this, see
<a href="../gallery/bars9.htm">
bars9
</a>
<dl>
<dt><dd><p>
<tt></tt><pre>
Alternate full-
Notation date notation
------------------- -----------
yymm yymmdd
yymmm ddmmmyy
yy/mm, yy-mm, etc. yy/mm/dd
yyyy/mm, yyyy-mm, etc. yyyy/mm/dd
yy yymmdd
mm/yy, mm-yy, etc. dd/mm/yy
mm/yyyy, mm-yyyy, etc. dd/mm/yyyy
yyqn yy/mm/dd
yyyyqn yyyy/mm/dd
nqyy yy/mm/dd
nqyyyy yyyy/mm/dd
</pre>
<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 <br>
<a href="../doc/Copyright.html">Copyright Steve Grubb</a>
<br>
<br>
<center>
<img src="../gallery/all.gif">
</center>
</td></tr>
</table>
</dl>
<p><hr>
Markup created by <em>unroff</em> 1.0, <tt> </tt> <tt> </tt>March 01, 2002.
</body>
</html>
|