DATA Step, Macro, Functions and more

Question about dynamically getting the number of each weekdays(MTWTFSS) AND ASSOCIATED DATES in each month in each year starting 2013.

Reply
Contributor SGB
Contributor
Posts: 41

Question about dynamically getting the number of each weekdays(MTWTFSS) AND ASSOCIATED DATES in each month in each year starting 2013.

https://communities.sas.com/message/190760#190760 - Related Question and Answers from the community!

My question regarding dynamically getting the number of each weekdays in all 12 months in a given year has been answered by HaiKuo, Quentin and Tom.

I want to know the dates associated with those weekdays as well.

I tried tweaking the existing code but it didnt work..

Year Month Day     num date

2013 Jan     Sun    4      Jan 6 2013

2013 Jan      Sun   4      Jan 13 2013

2013 Dec     Sat   4      Jan 7 2013

2013 Dec      Sat   4      Jan 14 2013

2014 Jan     Sun    4      Jan 6 2014

2014 Jan      Sun   4      Jan 13 2014

2014 Dec     Sat   4      Jan 7 2014

2014 Dec      Sat   4      Jan 14 2014

Something like this. 

Appreciate your time and help in this regard.

Thanks

SGB

Super User
Posts: 19,789

Re: Question about dynamically getting the number of each weekdays(MTWTFSS) AND ASSOCIATED DATES in each month in each year starting 2013.

Post the code you tried that doesn't work.

Contributor SGB
Contributor
Posts: 41

Re: Question about dynamically getting the number of each weekdays(MTWTFSS) AND ASSOCIATED DATES in each month in each year starting 2013.

Tom has answered this question in the other link.. Thanks a lot to Tom!

https://communities.sas.com/message/190760#190760

Ask a Question
Discussion stats
  • 2 replies
  • 152 views
  • 0 likes
  • 2 in conversation