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 / jugaadu

Sorry missed the data step here is the corrected Version;


%MACRO Data_Create;
%Do i = 1 %to 365;
DATA file&i;
INPUT a @@;
CARDS;
4*&i-3 4*&i-2 4*&i-1 4*&i
;
RUN;
%MEND;

%Data_Create;

Is This Answer Correct ?    3 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the difference between ceil and floor functions in sas?

713


How does the internal authentication work in sas? : sas-grid-administration

587


What is the function of output statement in a SAS Program?

619


What are the best sas programming practices for handling very large datasets? : sas-grid-administration

571


Did you used proc test? when?

1577






I have 3 years of work experience at a startup and recently got certified in Data Science with SAS. I need to know how to get into the analytics industry

1329


Explain what Proc glm does?

643


what is the difference between: x=a+b+c+d; and x=sum (of a, b, c ,d);? : Sas programming

613


what do the sas log messages "numeric values have been converted to character" mean? What are the implications? : Sas programming

694


Can you execute macro within another macro? If so, how would sas know where the current macro ended and the new one began? : sas-macro

702


name the scheduler for scheduling job and explain the scheduler? : Sas-di

600


Briefly explain input and put function?

638


What is a pdv and what are its functions?

603


Mention the category in which sas informats are placed?

631


Which command is used to perform sorting in sas program?

599