STAT 540 Homework 4 -- Fall 2019 1. Write a SAS program to read in (and also print) the data file tshirt.txt given on the course web page. Please have SAS read in the data file directly from the web address: http://people.stat.sc.edu/hitchcock/tshirt.txt and NOT from a file location on your own computer. The variables for each observation, in order, are: size, color, price, shipping cost. (The monetary variables should appear without dollar signs in the printed data set.) 2. Write a SAS program to read in (and also print) the data file districtdata.txt given on the course web page. Please have SAS read in the data file directly from the web address: http://people.stat.sc.edu/hitchcock/districtdata.txt and NOT from a file location on your own computer. Note that the symbol "|" is the delimiter that separates data values. The variables for each observation, in order, are: district, number of teachers, number of students, rating. 3. Write a SAS program to read in (and also print) the data file champ36pres.txt given on the course web page. Please have SAS read in the data file directly from the web address: http://people.stat.sc.edu/hitchcock/champ36pres.txt and NOT from a file location on your own computer. The variables you should read in for each data line, in order, are: year, team, wins, losses, ties, coach. Note that the data are arranged in COLUMNS in the data file. (Hint: You may want to use some options to the INFILE statement given on pg. 56-57 of the text.) ** In the champ36pres.txt file, do not manually remove the introductory lines to the data file -- rather, have your code tell SAS to ignore those lines. ** For the year when there are two champions (like 1957), it's fine to have SAS read in the year as missing for the second team for that year. I'll give you a bonus point if you can get SAS to put the correct year for that second team (hint: you can read ahead to pg. 92-93 of the text to figure out a way to do it). NOTE: Please write your code to read in the files as they are, i.e., do not edit the data files before having your SAS code read in the data. NOTE: You MUST intersperse comments in your SAS program to explain in detail what your SAS statements are supposed to be doing. Please be generous with your comments, since you will be graded not only on the correctness of the code, but the clarity and amount of comments. Remember that SAS comments are typed as: /* comment */ or *comment; DO NOT put R-style comments (with #) in your SAS code!!! You can upload your .txt file with your SAS code and comments into Blackboard as usual. As with the other homeworks, to ensure that the grader will be able to grade your submission: * Please save your document as a plain text (.txt) file before uploading. * Please ensure that EVERY line in your submitted text file EXCEPT your SAS code is placed in "comments". That way, the grader will be able to copy everything in the file into SAS and have the program run without a problem. * Please include detailed comments explaining your code. You will be graded on the quality of your comments, as well as the correctness of your code.