ST 445 -- SUMMER 2012 HOMEWORK #5 -- DUE WEDNESDAY, 20 JUNE2012 Among the controversial votes during the past NC legislative session were some taken early in the morning. To assess whether the times were unusual, the Raleigh News and Observer (story, 13 Jan 2012) did some analysis of the times when votes occurred. Our goal is to replicate some of their study to assess the story's accuracy. Use files named '20xxVotes.txt' where xx goes from 01 to 09 (five files). Your task is to read them all in, put them together, and do some analysis. The format of the data is roll call sequence number (numeric) chamber (S or H, character) date (yymmdd10.) time (hhmmss.000, so use hhmmss8. and read another numeric variable and drop it) prefix (Chamber, bill, resolution etc. -- character) billid (numeric) yes votes no votes excused absences excused votes didn't vote total yes/no votes ... and more stuff that we don't care about *** the data are semicolon delimited, but there's a space between the date and the time, so use two delimiters, space and semicolon, as well as dsd *** a) Read in the data from each of the five files. Create a variable HOD (hour of the day) using the SAS function hour(x) which gives the hour from a time variable. Also create a variable WHEN (character or numeric) that roughly corresponds to morning, afternoon, evening, and night. b) Check to see if the total yes/no votes matches the sum of the two. (Since these are integers, no need to worry about rounding.) c) Put the datasets from these five files together for analysis. d) Create a frequency table of HOD and chamber. (how many votes at each hour for each chamber) e) Determine whether the time of day affects the number of votes. For each chamber, do an analysis of variance of number of votes with WHEN as the factor. FOR ALL EXERCISES: Hand in (paper) (1) The answers to any questions asked. (2) Your program * With at least as many comments as you have toes! * (3) Your output