Finance 599 Assignment 3

This assignment requires you to access the CRSP files, get some data, and analyze it.   All in Fortran.  (We will analyze data in SAS in a couple of weeks).  You will probably want to access the CRSP stock user guide.   I have it in .pdf format here on the Internet, and it is on the Finance department server in /data/share/everyone/crsp/.  I keep a copy of the user guide on my hard drive since I'm not very patient.

Below is a program "snippet" that will help you get started with CRSP.   You can cut and paste into pico:

      program getdata
      include ‘us.txt’
      call udopen(3)
  100 call usgetper(1,inext,all,*900)

      process data for a
      company

      goto 100

Alternately, you can copy the program ~prdaves/public/getcrsp.f  which has this snippet, and some other comments in it.

If you put in a permno in place of inext in the program, you will get data for that particular company.  This is a simple assignment:

1.  read a permno from the file /u08/prdaves/public/assign3.dat     (you can copy it to your directory, or just put in the entire path in the open statement)

2.  access the CRSP database for that permno

3.  write out the following information with some appropriate verbage to tell what you are writing:

4.  Go back to 1 and read another company permno from the file.

Note:  Make sure you have an end=... statement on the file read so you don't bomb when you get to the end of the input file (don't use a do i=1,5 do loop).