Answered step by step
Verified Expert Solution
Question
1 Approved Answer
STAT 440 - Homework 01 Students are encouraged to work together on homework. However, sharing or copying any part of the homework is an infraction
STAT 440 - Homework 01 Students are encouraged to work together on homework. However, sharing or copying any part of the homework is an infraction of the University's rules on Academic Integrity. Final submissions must be uploaded to our Compass 2g site on the Homework page. No email, hardcopy, or late submissions will be accepted. Getting the program file ready a. Create a folder on the hard drive with the following pathname - C:\\440\\hw01. Save all data files accompanying this assignment in that folder. If you cannot create the folder because you are working on a university computer and don't have permission, create the ...\\440\\hw01 folder elsewhere. b. Assign the library reference hw01 to the folder 'C:\\440\\hw01'. Use this library as your permanent library for this assignment. If you could not create the folder, assign the library reference hw01 to your ...\\440\\hw01 folder. Note: If you are using a folder other than 'C:\\440\\hw01', you must change any pathname references in your program file to 'C:\\440\\hw01' before submitting your homework. Submitting your work to Compass 2g You are to submit two (and only two) files for your homework submission. 1. Your SAS program file which should be saved as HWn_YourNetID.sas. For example, my file for the HW01 assignment would be HW01_dunger.sas. All program statements and code should be included in one program file. 2. Your Report including all relevant output to address the exercises. For this homework, use ODS to send your results to a Portable Document Format (PDF) file called HWn_YourNetID.pdf. For example, my file for HW01 would be HW01_dunger.pdf. Only include your final set of output. Do not include output for every execution of your SAS program. Use the template file hw01 template.sas as your guide. You have an unlimited number of submissions, but only the last one will be viewed and graded. Homework submissions must always come as a pair of files, as described above. 1. You will be working with the SAS data file pricedata which contains simulated monthly sales data. It is located in the sashelp library. a. Print the descriptor portion of this SAS data file. (Include results in the HW Report.) Read the results to become familiar with the contents of this data set. b. Read in the SAS data file and create a temporary SAS data file called pricing_NetID. Change the format of Date so that the full date is represented in a \"month/day/4-digit year\" type structure. For example, JAN90 would show as 1/1/1990. Change the format of the variables Price and Cost so that their values appear monetarily and are rounded to the nearest hundredth. For example, 41.9 would show as $41.90. Change the format of the variable Discount so that the displayed value shows as a percentage rather than a decimal. For example, 0.13 would show as 13%. Change the label of the variable Sale to \"Units Sold\". Subset the observations so that only those months are included in which more than 300 units were sold and the difference between the Unit Price and Unit Cost was less than $40. Only the variables Date, Sale, Price, Discount, Cost, and ProductName should be in the final data set. c. Print the descriptor portion of pricing_NetID. (Include results in the HW Report.) d. Print the data portion of pricing_NetID. (Include results in the HW Report.) 2. You will be working with the SAS data file employee_roster which contains many variables regarding the employees of the Orion corporation. a. Print the descriptor portion of your new SAS data file. (Include results in the HW Report.) Read the results to become familiar with the contents of this data set. b. Read in the SAS data file and create a temporary SAS data file called top_earners_NetID that contains all Orion employees who make over $70,000. Also change the labels of Job_Title to \"Position\" and Salary to \"Yearly Salary\". c. Print the data portion of top_earners_NetID including only each employee's name, position, and salary in that order. (Include results in the HW Report.) Without creating a new SAS data set, use the employee_roster data set to ... d. Print a table of all male employees in the Administration section earning no less than $25,000 but no more than $30,000 in salary. Include only the employees' names, gender, section, and salary. (Include results in the HW Report.) e. Print a table of all employees whose first name begins with either C, D, or E. Include only the employees' names, ID, and group. (Include results in the HW Report.)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started