<< date2num Time series date2num_m >>

Grocer >> Time series > date2num_fq

date2num_fq

transforms a date into a number and its frequency

CALLING SEQUENCE

[num,fq]=date2num_fq(dat)

PARAMETERS

Input

* dat = a date string

* indw = 'w' if the date is given as a day date but corresponds to a week (optional)

 

Output

* num = the numerical representation of the dates

* fq = its frequency

DESCRIPTION

Transforms a date into its numerical representation and its frequency.

EXAMPLE

[num,fq]=date2num_fq('1985q4')
// return the numerical representation and frequency of the quarterly date '1985q4'
 
num,fq]= date2num_fq ('2002a')
// return the numerical representation and frequency of the yearly date '2002a'.
 
[num,fq]= date2num_fq ('97m12')
// return the numerical representation and frequency of the monthly date '97m12'.
 
[num,fq]= date2num_fq ('2002/03/15','w')
// return the numerical representation and frequency of the daily date '2000/03/15'.

AUTHOR

Eric Dubois 2002-2007

Report an issue
<< date2num Time series date2num_m >>