create macros---you have 365 number of data and you need to
merge it throw the macros,,,,,,
data file1;
input a @@;
cards;
1 2 3 4
;
run;
data file2;
input a @@;
cards;
5 6 7 8
;
run;
data file3;
input a @@;
cards;
9 10 11 12
;
run;data file4;
input a @@;
cards;
13 14 15 16
;
run;
Answer Posted / ashutosh
%macro mydata(my,n);
data XXX;
merge
%do i=1 %to &n;
&my&i
%end;
;
by a;
run;
%mend;
%mydata(file,4);
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
what is sas and what are the functions? : Sas-administrator
Mention the category in which sas informats are placed?
What do you code to create a macro? : sas-macro
what is null hypothesis? why do you consider that?
If you have a dataset that contains 100 variables, but you need only five of those, what is the code to force SAS to use only those variables?
how do the in= variables improve the capability of a merge? : Sas programming
How to sort in descending order?
what is data governance? : Sas-di
What is the SAS data set?
how are numeric and character missing values represented internally? : Sas programming
How would you code a merge that will write the matches of both to one data set, the non-matches from the left-most data?
How you can read the variables that you need?
what are the considerations when picking a SAS/STAT procedure?
What is substr function?
List out some key concept of SAS