Hi,
I understand the weekday interval in intnx function but given that I don't have experience in finance, I cannot really figure out when it is useful.
Would you have an explaination for dummies.
Let's take an example. September 18th is a Monday.
By default, the weekday interval uses Saturday and Sunday as weekends.
Each day going from Monday to Thursday starts and ends on the same day.
The interval of any date between Friday and Sunday starta on the Friday and enda on the Sunday.
data demo (drop=i);
do i=1 to 7;
_date='18SEP2022'd+i;
output;
end;
run;
data demo;
set demo;
_weekday_b=intnx('weekday',_date,0,'b');
_weekday_e=intnx('weekday',_date,0,'e');
run;
proc print data=demo noobs;
format _date _week: weekdate.;
run;
My guess: when there is no change on the weekend, people might just want their programs to keep running as if it was on Friday. Saturday and Sunday reports would be like Friday reports.
Happy to hear any more valuable concrete explainations.
... View more