Hello,
I am carrying out an event study application. At the moment, I have some troubles in setting the Event Window. Differently from other questions asked in the community, my events are endogenous. I am using a dummy variable named jumps_pa to detect such events. I should require to set an event window going from t-30 to t+30, where t is the event date. For each event, I need to set such an event window, keeping the data in the columns exc_retadj retidio below for the preceding and following dates.
my data are daily data, sorted by permno, and arise after several steps from crsp datbase. in particular, they look like this
permno date exc_retadj retidio jumps_pa
10000 1/01/x 1 if jump, 0 if no jump.
.... .... .....
Could anybody help create a table to sort data according to my needs?
Thanks
Riccardo
Hello,
I'm really not sure what you're after. Your question is not very clear to me. I'm also wondering why you put in in the "statistical procedures" board.
Maybe you can clarify your question by using the below code:
data have;
input permno date jumps_pa;
informat date ddmmyy10.;
format date exc_retadj retidio ddmmyy10.;
exc_retadj = INTNX('DAY',date,-30,'SAME');
retidio = INTNX('DAY',date,+30,'SAME');
cards;
10000 21/01/2021 1
;
run;
/* end of program */
Cheers,
Koen
Hello,
I'm really not sure what you're after. Your question is not very clear to me. I'm also wondering why you put in in the "statistical procedures" board.
Maybe you can clarify your question by using the below code:
data have;
input permno date jumps_pa;
informat date ddmmyy10.;
format date exc_retadj retidio ddmmyy10.;
exc_retadj = INTNX('DAY',date,-30,'SAME');
retidio = INTNX('DAY',date,+30,'SAME');
cards;
10000 21/01/2021 1
;
run;
/* end of program */
Cheers,
Koen
Save $250 on SAS Innovate and get a free advance copy of the new SAS For Dummies book! Use the code "SASforDummies" to register. Don't miss out, May 6-9, in Orlando, Florida.
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.