ECON 424/AMATH 462: Introduction to Computational Finance and Financial Econometrics

Home
Syllabus
Homework
Notes 
Excel Hints 
R Hints
Announcements
Links
Project
Review

Moodle

Homework Assignments

Summer 2013

  • New homework assignments are posted every Tuesday after class. Assignments are due at the beginning of class one week after they are assigned and are to be submitted electronically through homework dropbox on the class Moodle page.  For R work, I suggest that you copy and paste statistical output and graphs from R into a word processor (e.g MS Word).

  • The assignments and solutions are in Adobe Acrobat files (.pdf format). You will need the Adobe Acrobat viewer to view and print the files. Most browsers on campus have the Acobat plug-in installed. If you don't have the Acrobat plug-in you can get it free at Adobe's web site.

Last updated: August 22, 2013

 

Assignment

Due Date

Programs/Data

Solutions

Tuesday 7/2/13 at the beginning of class

download data from finance.yahoo.com. See below for instructions.

econ424lab1.r

sbuxPrices.csv

solutions

Excel solutions

 

Tuesday 7/9/13 at the beginning of class

 

None needed

Tuesday 7/16/13 at the beginning of class

econ424lab3.r

Tuesday 7/23/13 at the beginning of class

 

econ424lab4.r

Thursday 8/1/13 at the beginning of class

econ424lab5.r

 

Thursday 8/6/13 at the beginning of class econ424lab6.r
econ424lab7returns.csv

Thursday 8/13/13 at the beginning of class

econ424lab7.r

Tuesday 8/20/13 at the beginning of class

econ424lab8.r
econ424lab8returns.csv

 

To get data from Yahoo! do the following for each series to be downloaded:

  1. Point your browser to the Yahoo! finance site.

  2. In the Get Quotes box type the symbol of the stock for which you want data. For example, the symbol for Microsoft is MSFT. If you do not know the ticker symbol use the symbol lookup link at the right of the box.

  3. The recent quote for your stock as well as a wealth of other information will be presented on a new page. To get historical prices, click the historical prices link on the upper left panel of the page.

  4. A new page will open and you will be able to specify the date ranges for the data to be downloaded and the frequency of the data (daily, weekly or monthly).

  5. After setting the date and frequency information, click the get prices button.  This brings up a table with your specified data.

  6. At the bottom of the displayed table click on Download to Spreadsheet. This will bring up a Save As dialogue box. Specify a name for the file and save to disk. Each file will contain 6 columns (as in the table below). For monthly data, the column labeled Open gives the opening price at the beginning of the month, the column labeled High gives the highest price during the month, the column labeled Low gives the lowest price during the month, the column labeled Close gives the closing price during the month and the column labeled Volume gives the total monthly volume. The open and the close data have been adjusted for dividends and stock splits. Use the (adjusted) close data for your analysis. 

After downloading your data file, you need to reverse the time ordering of the data in the file. To reverse the time ordering of the data do the following.

Open the .csv file containing your data in Excel. You should see data arranged like the following

Date

Open

High

Low

Close

Volume

Jun-99

80.625

90.25

78.4375

90.1875

23414100

May-99

81.4375

81.5

78.125

80.6875

27182000

Apr-99

91.25

92.875

79.875

81.3125

24916100

Mar-99

74.7812

94.625

74.75

89.625

21979600

Feb-99

87.7188

87.9688

74.75

75.0625

17625300

Notice that the most recent data is at the top of the spreadsheet. To reverse the date ordering of the data, highlight all of the data (including the column headers). Then select Data/Sort which brings up the Sort dialogue box. In the Sort by box choose Date, click the Ascending option and the OK box. Your data will be sorted from the earliest date to the latest date.