What is LAG function?How is it used? can any one explain
Answer Posted / basha
hai gajari
this is basha from chennai no phones no mails why? what
happened man?
ok lets see answer
lag function returns value from que
ex:-
data gajari;
input chindhi 8. @@;
datalines;
1 2 3 4 5
;
run;
data rao;
set gajari;
chore=lag(chindhi);
run;
output:-
obs chndhi chore
1 1 .
2 2 1
3 3 2
4 4 3
5 5 4
ok bye
take care
basha
TVS F&S
| Is This Answer Correct ? | 9 Yes | 0 No |
Post New Answer View All Answers
Which function is used to count the number of intervals between two sas dates?
Will it bother you if the guy at the next desk times the frequency and duration of your bathroom or coffee breaks on the grounds that ?you are getting paid twice as much as he is??
What function CATX syntax does?
Describe 5 ways to do a “table lookup” in SAS?
Give some examples where proc report’s defaults are same as proc print’s defaults?
if a variable contain dates like "2015/01"---"2015/12" (yymm) ,How to add day to those dates,if them month is jan then 31 if the month is feb then 28 so on ...
How do you debug and test your SAS programs?
What is proc sort?
what is the difference between: x=a+b+c+d; and x=sum (of a, b, c ,d);? : Sas programming
how are numeric and character missing values represented internally? : Sas programming
What are the different versions of sas that you have used until now? : sas-grid-administration
What’s the difference between var b1 – b3 and var b1 — b3?
hi all, I need the SAS DI DUMP(A00 260) for attending the certification. if any one have, pls provide it.Please Email to vrpotluri@hotmail.com. Thanks - Ramana
How to include or exclude specific variables in a data set?
how does sas handle missing values in sort order? : Sas programming