On Tue, Aug 2, 2022 at 6:44 AM Riccardo (Jack) Lucchetti
<p002264(a)staff.univpm.it> wrote:
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.
NAs seem the right thing to me. That's now in git.
Allin