Plotting Functions

For the syntactically challenged (is that a word?) plotting functions can provide an ‘explanation’ that can become obscure when put into words.

Here’s a silly little example.

1
2
3
/*PlotDateNum*/ 
 
Plot(DateNum(),"DateNumber",1);

Insert the formula, using daily bars, and scroll the datenum() plot using the keyboard arrows.

PlottingFunctions001

Note: The DateNum plot will display using two decimal points, by default. Ignore them as they are not relevant. They have been edited out of the image in this example.

Now turn to the AFL reference manual for comparison!

SYNTAX         datenum()

RETURNS      ARRAY

FUNCTION    Returns the array with numbers that represent quotation dates coded as follows: 10000 * (year – 1900) + 100 * month + day, so 2001-12-31 becomes 1011231 and 1995-12-31 becomes 951231

Of course, some people will prefer the latter version and some people will prefer the former, depending on their psychological typology.

1 Star2 Stars3 Stars4 Stars5 Stars (2 votes, average: 5.00 out of 5)
Loading ... Loading ...

No comments yet. Be the first.

Leave a reply