How to alternate between two variables based on the day of the week - SAS 9.4

Reply
New Contributor
Posts: 2

How to alternate between two variables based on the day of the week - SAS 9.4

I need to change first day of the week to "Tuesday".

Couldn't find any stored procedure for the same.

 

 

SAS Moderator
Posts: 62

Re: How to alternate between two variables based on the day of the week - SAS 9.4 [how to improve your question]

Posted in reply to abhithelucifer0

Hello @abhithelucifer0,


Your question requires more details before experts can help. Can you revise your question to include more information? 

 

Review this checklist:

  • Specify a meaningful subject line for your topic.  Avoid generic subjects like "need help," "SAS query," or "urgent."
  • When appropriate, provide sample data in text or DATA step format.  See this article for one method you can use.
  • If you're encountering an error in SAS, include the SAS log or a screenshot of the error condition. Use the Photos button to include the image in your message.
    use_buttons.png
  • It also helps to include an example (table or picture) of the result that you're trying to achieve.

To edit your original message, select the "blue gear" icon at the top of the message and select Edit Message.  From there you can adjust the title and add more details to the body of the message.  Or, simply reply to this message with any additional information you can supply.

 

edit_post.png

SAS experts are eager to help -- help them by providing as much detail as you can.

 

This prewritten response was triggered for you by fellow SAS Support Communities member @KurtBremser

.
Respected Advisor
Posts: 4,736

Re: How to alternate between two variables based on the day of the week - SAS 9.4

[ Edited ]
Posted in reply to abhithelucifer0

@abhithelucifer0

Below should give you a very good start when it comes to dealing with dates in SAS.

http://documentation.sas.com/?docsetId=lrcon&docsetTarget=p1wj0wt2ebe2a0n1lv4lem9hdc0v.htm&docsetVer...

 

SAS function INTNX() can be used to shift a SAS date value. 

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