What is LAG function?How is it used? can any one explain
Answer Posted / naveen
this Question was raised by saddi soorath....
lag function enables you to have the previous value.
we have the following data
Name num
Naveen 1
Naveen 2
Basha 1
Basha 2
so in data step
if u give num1 =lag(num) you will have the following result
Name num num1
Naveen 1 .
Naveen 2 1
Basha 1 .
Basha 2 1
Thanks and regards
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
Mention what are the data types does SAS contain?
Why double trailing @@ is used in input statement?
If you were told to create many records from one record, show how you would do this using array and with proc transpose?
what is sas application server? : Sas-di
how many types prompting framework can be broken down to? : Sas-bi
what are the best practices to process the large data sets in sas programming? : Sas-administrator
why a stop statement is needed for the point= option on a set statement?
Explain why double trailing @@ is used in input statement?
explain about sas business intelligence? : Sas-bi
Explain the use of proc print and proc contents?
it will become easy if uuu provide website linkssss and list of consultanciessssss
What are the special input delimiters used in SAS?
Explain the purpose of substr functions in sas programming.
What would be the value of month at the end of data step execution and how many observations would be there?
how can you create zero observation dataset? : Sas programming