Hi all. Consider this script:
<hansl>
nulldata 12
setobs 5 2020-02-01
loop i = 6 .. 12
date = sprintf("2020-02-%02d", i)
printf "%s -> %d\n", date, obsnum(date)
endloop
</hansl>
the output I get is:
<output>
2020-02-06 -> 4
2020-02-07 -> 5
2020-02-08 -> 6
2020-02-09 -> 7
2020-02-10 -> 6
2020-02-11 -> 7
2020-02-12 -> 8
</output>
which is of course correct from Monday to Friday, but obviously wrong for
weekends. What do you guys think we should do in these cases? I reckon we
ought to return NAs, but I'm open to other ideas.
-------------------------------------------------------
Riccardo (Jack) Lucchetti
Dipartimento di Scienze Economiche e Sociali (DiSES)
Università Politecnica delle Marche
(formerly known as Università di Ancona)
r.lucchetti(a)univpm.it
http://www2.econ.univpm.it/servizi/hpp/lucchetti
-------------------------------------------------------