Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

/*Question 2: First, read the following data into SAS. This data set shows the d

ID: 2907350 • Letter: #

Question

/*Question 2: First, read the following data into SAS. This data set shows the daily stock prices of a company at market close over the four weeks in June 2018. For instance, the first row is for the week starting on Monday, June/04/2018. The closing price of that Monday is $3, that of Tuesday is $2.75, so on and so forth, until that Friday. 04JUN2018 3.00 2.75 2.25 2.00 2.75 11JUN2018 2.85 3.05 3.00 3.50 3.25 18JUN2018 4.25 4.50 4.75 5.00 4.50 25JUN2018 4.00 3.75 3.00 3.75 3.00 After reading the data into SAS, please create a SAS data set that shows the number of days in each week when the closing price is higher than the average price of that week. Next, based on the closing price, please calcuate the daily returns of this stock, i.e. the percentage daily changes in price. Hint: you may use LAG function in the calculation of returns.*/

Explanation / Answer

Date Mon Tue Wed Thu Fri Avg price higher closing price days 04JUN2018 3.00 2.75 2.25 2.00 2.75 2.55 Mon, Tue, Fri 11JUN2018 2.85 3.05 3.00 3.50 3.25 3.13 Thu, Fri 18JUN2018 4.25   4.50 4.75 5.00 4.50 4.6 Wed, Thu 25JUN2018 4.00 3.75 3.00 3.75 3.00 3.5 Mon, Tue, Thu