meena


{ City } delhi
< Country > india
* Profession * technical
User No # 90219
Total Questions Posted # 0
Total Answers Posted # 2

Total Answers Posted for My Questions # 0
Total Views for My Questions # 0

Users Marked my Answers as Correct # 19
Users Marked my Answers as Wrong # 5
Questions / { meena }
Questions Answers Category Views Company eMail




Answers / { meena }

Question { Barclays, 15890 }

Suppose there is a SAS dataset with following values -
Parent Child
A B
B C
D E
F G
G H
H I
and so on…..
This goes onto 1000s of observations/rows.
Now how do we identify from this dataset Grandparents and
Grandchildrens ?


Answer

data dx;
infile datalines dsd dlm=',';
input parent :$8. child :$8.;
datalines;
A,B
B,C
D,E
F,G
G,H
H,I
;;;;
run;

data dy(rename=(parent=grandfather child=father)) ;
merge dx(firstobs=2 in =a rename=(child=grandchild
parent=child ))
dx(firstobs=1 in =b );
by child;
if a and b;
run;
proc print;
var grandfather father grandchild;
run;

Is This Answer Correct ?    15 Yes 4 No

Question { Accenture, 21382 }

When you will use nowd option in report???


Answer

NOWD option runs the Proc Report without the report window.
Sas writes in traditional output file like in html body,rtf
or pdf files.

Is This Answer Correct ?    4 Yes 1 No