Homework 1 instructions
pdf
keyboard_arrow_up
School
Purdue University *
*We aren’t endorsed by this school
Course
506
Subject
Statistics
Date
Feb 20, 2024
Type
Pages
2
Uploaded by BailiffKangaroo6144
STAT 506: Homework 1
You should first download the Data folder for the Programming 1 course from Brightspace; it is available in a zip file called “PG1.zip.” You will need to unzip it and follow the instructions on running the cre8data.sas program. Make sure it is in a location that is accessible from where you are running SAS. The folder contains all the datasets and SAS programs that go along with the SAS course we are following.
Also, in the assignments when I ask for you to “submit a screenshot”, all you need to do is push the ‘Print Screen’ button on your computer (or use the Snipping Tool / Snip & Sketch app in Windows or Shift-Command-4 on a Mac) and then paste the image into your homework submission. Also, any time there are italicized
instructions at the end of a step, those are my instructions for you to show me your work.
Be aware that this first assignment is shorter than future assignments will be. Use this as a “warm up.” Take the extra time to play around a bit and familiarize yourself with SAS, after making sure you’re comfortable with how you’ll be accessing it this semester (downloaded on PC, using Purdue labs, online OnDemand for Academics, and/or Software Remote).
1. Submitting a Program
data hw1; set sashelp.cars; run; proc print data=hw1 noobs; var Make Model MPG_Highway; where MPG_Highway > 39; run; a.
How many steps are in the above code? How many statements are in the above code?
b.
Copy the above code into the Editor window. Submit the program for execution. How many rows and columns are in the report (excluding the variable name row) in the Results Viewer window?
c.
Examine the Log window. Based on the log notes following the DATA step, how many observations and variables are in the sashelp.cars
table?
2. Diagnosing and Correcting Syntax Errors
proc prnt data=sashelp.cars; var EngineSize hoRsepoWeR /* This line is a comment and we don't want it to run; RUN; a.
The above SAS code might have some errors. State the error(s).
b. Correct the error(s) and submit the program. Show the final code and the output showing the first five observations.
3.
Understanding SAS Dates
a.
The Justice League of America debuted in comics on December 29, 1959. What is that as a SAS date?
b.
When stored in a variable as a SAS date, what would its default length (byte size) be?
4. Examining the Descriptor Portion of a SAS Table
a.
Write a PROC CONTENTS step to display the descriptor portion of the sashelp.Holiday table
. Show your code.
b. Submit the program and answer the following questions:
How many observations (rows) are in the data set? How many variables (columns) are in the data set? What is the length (byte size) of the variable desc
?
5. Accessing a SAS Data Library
a.
Write and submit the appropriate LIBNAME statement to provide access to the pg1/data folder. Call the libref “pg1”. Submit the libname statement.
b. Check the log to confirm that the SAS data library was assigned. Submit this portion of the log.
c. Add a PROC CONTENTS step to display the descriptor portion of the table pg1.storm_range
. Submit the code and the output. (Yes, there will be a lot of output.)
6. Using PROC IMPORT for CSV Files
a.
Download the file hw1data.csv from Brightspace. You will want to take note of the location of the downloaded file. If you’re working with SAS OnDemand or Software Remote, you’ll have to then upload it to the remote environment. Write a PROC IMPORT step to read into SAS as a table named work.hw1data
. Submit the code.
b.
The PROC IMPORT you just ran created a new file named hw1data.sas7bdat
on your system. After you end your SAS session (don’t do that right now), what will happen to that file and why?
c.
Then
run the below code. Submit a screenshot of the output.
proc print data=work.hw1data; run;
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help
Related Documents
Related Questions
Just need part D
arrow_forward
Answer the question below in the picture
arrow_forward
Thank you for any feedback on this one.
arrow_forward
Pls help
might need to use excel
arrow_forward
Recently, management at Oak Tree Golf Course received a few complaints about the condition of the greens. Several players complained that the greens are too fast. Rather than react to the comments of just a few, the Golf Association conducted a survey of 100 male and
100 female golfers. The survey results are summarized here.
Excel File: data02-31.xlsx
Male Golfers
Green Condition
Gender Too Fast
Male
Handicap
Under 15
15 or more
25
25
a. Complete the crosstabulation shown below.
Green Condition
Female
Too Fast
10
Fine
Fine
40
Female Golfers
Total
Green Condition
Handicap
Under 15
15 or more
Too Fast
1
Fine
9
39 51
Total
Which group shows the highest percentage saying that the greens are too fast?
- Select your answer -
b. Refer to the initial crosstabulations. For those players with low handicaps (better players), which group (male or female) shows the highest percentage saying the greens are too fast?
For the low handicappers, the - Select your answer - have a higher percentage who…
arrow_forward
The U.S. Geological Survey monitors and reports on earthquakes, providing daily real-time, worldwide earthquake lists. Some of the information for four of the 105 earthquakes of magnitude 1.5 or greater that occurred on May 10, 2013, is shown in the following table. Magnitude is given on the Richter scale and NST stands for the number of stations that reported the activity on the same earthquake. Complete parts (a) through (e) below.
Time
Magnitude
Depth (km)
NST
Region
00:03:16
1.7
75.9
29
Alaska
04:59:11
1.7
134.9
18
Alaska
08:27:04
2.8
64.0
21
Alaska
23:30:09
4.2
10.0
34
China
a. Identify the type of data provided by the information in the first column of the table. Also identify the variable under consideration.
Quantitative, Continuous,
Qualitative,
Quantitative, Discrete,
region where the earthquake occurred
depth of the earthquake in kilometers
number of stations reporting the earthquake…
arrow_forward
Vince had 10 weeks to get in shape for a race. The line graph shows how many miles he ran per training session each week.
10-Week Training
7
6.
4
2
0 1 2 3 4 5 6 7 8 9 10
Week
© 2020 StrongMind. Created using GeoGebra.
What is the total number of miles that Vince ran per session in weeks 5, 6, 7, and 8?
Enter your answer as a whole number, like this: 42
Miles
arrow_forward
Q3 needed to be solved correctly in 30 minutes and get the thumbs up please show neat and clean work
arrow_forward
For each of the worksheets, Total Profit per Region and Sales per Month, decide which type of chart would best represent the data. Please be sure to discuss why you would choose these types of charts based on the data you would be visualizing.
arrow_forward
The r code for side by side boxplot of vitamind v newage and vitamin d v country.
Scatterplot code for relationship between vitamin d level and age.
arrow_forward
Help me fast so that I will give Upvote.
arrow_forward
Recently, management at Oak Tree Golf Course received a few complaints about the condition of the greens. Several players complained that the greens are too fast. Rather than react to the comments of just a few, the Golf Association conducted a survey of 100 male and
100 female golfers. The survey results are summarized here.
Excel File: data02-31.xlsx
Male Golfers
Male
Green Condition
Handicap
Under 15
15 or more
25
25
a. Complete the crosstabulation shown below.
Green Condition
Gender Too Fast Fine
Female
35
40
Too Fast
10
65
60
Fine
40
Total
100
100
Female Golfers
200
Green Condition
Handicap
Under 15
15 or more
Too Fast
1
Note: This exercise is an example of Simpson's Paradox.
39
Fine
9
Total
75
125
Which group shows the highest percentage saying that the greens are too fast?
Females, at 40%
b. Refer to the initial crosstabulations. For those players with low handicaps (better players), which group (male or female) shows the highest percentage saying the greens are too fast?
For…
arrow_forward
Plz answer all the parts and get thumb up
arrow_forward
Now monitor the process. An additional ten days of data have been collected, see table labeled “1st 10 Days of Monitoring Reservation Processing Time” in the Data File.
Develop Xbar and R charts for the 1st 10 days of monitoring. Plot the data for the 1st 10 days on the Xbar and R charts.
Is the process in control? If the control chart indicates an out-of-control process, note which days, the pattern, and whether it is the Xbar or R chart.
Based on the X-bar and R Charts that you developed for the 1st 10 days of data, is the process in control?
Group of answer choices
No. The X-bar and R Charts are both out of control.
No. The X-bar Chart is in control, but the R Chart is out of control.
No. The R Chart is in control, but the X-bar Chart is out of control.
Yes. The X-bar and R Charts are both in control.
arrow_forward
I need #8 and 9
arrow_forward
Just need help with part 3, thank you!
arrow_forward
Just calculate to part c, d and e with detail.
arrow_forward
STATS 1700
For each of the following studies, make a chart of the four possible correct andincorrect decisions, and explain what each would mean. Each chart should belaid out like Table 6-1, but put into the boxes the possible results, using thenames of the variables involved in the study. (a) A study of whether increasing the amount of recess time improves schoolchildren’s in-class behavior. (b) A study of whether color-blind individuals can distinguish gray shades betterthan the population at large. (c) A study comparing individuals who have ever been in psychotherapy to thegeneral public to see if they are more tolerant of other people’s upsets thanis the general population.MyStatLab Making Sense of S
arrow_forward
tion 2 of 15
Last summer, the Smith family drove through seven different states and visited various popular landmarks. The prices of gasoline
in dollars per gallon varied from state to state and are listed below.
$2.34, $2.75, $2.48, $3.58, $2.87, $2.53, $3.31
Click to download the data in your preferred format.
CrunchIt! CSV Excel JMP Mac Text Minitab PC Text R SPSS TI Calc
Calculate the range of the price of gas. Give your solution to the nearest cent.
range:
dollars per gallon
DELL
&
4.
7
8.
arrow_forward
As suburban gardeners know, deer will eat almost anything green. In a study of pine seedlings at an environmental center in Ohio, researchers noted how deer damage varied with how much of the seedling was covered by thorny undergrowth.
Deer Damage
Thorny cover
Yes
No
None
60
151
<1/3
76
158
1/3 to 2/3
44
177
>2/3
29
176
Data provided by Patricia Heithaus and the Department of Biology at Kenyon College.
© Macmillan Learning
What is the probability that a randomly selected seedling was damaged by deer? Give your answer to four decimal places.
probability:
arrow_forward
Describe an application of linear programming you might find useful where you work, in your personal life, or in a course you are taking.
Be specific with your answers. This is an opportunity for you to showcase what you have learned about linear programming and your ability to apply your knowledge to real-world applications.
arrow_forward
A chef plans to mix
100%
vinegar with Italian dressing. The Italian dressing contains
16%
vinegar. The chef wants to make
210
milliliters of a mixture that contains
48%
vinegar. How much vinegar and how much Italian dressing should she use?
Note that the ALEKS graphing calculator can be used to make computations easier.
arrow_forward
Make graphs for each section (a,b,c,d, and e).
arrow_forward
PLEASE HELP ME WITH THISS!!
arrow_forward
SEE MORE QUESTIONS
Recommended textbooks for you
Algebra for College Students
Algebra
ISBN:9781285195780
Author:Jerome E. Kaufmann, Karen L. Schwitters
Publisher:Cengage Learning
Elementary Geometry for College Students
Geometry
ISBN:9781285195698
Author:Daniel C. Alexander, Geralyn M. Koeberlein
Publisher:Cengage Learning
Mathematics For Machine Technology
Advanced Math
ISBN:9781337798310
Author:Peterson, John.
Publisher:Cengage Learning,
Related Questions
- Pls help might need to use excelarrow_forwardRecently, management at Oak Tree Golf Course received a few complaints about the condition of the greens. Several players complained that the greens are too fast. Rather than react to the comments of just a few, the Golf Association conducted a survey of 100 male and 100 female golfers. The survey results are summarized here. Excel File: data02-31.xlsx Male Golfers Green Condition Gender Too Fast Male Handicap Under 15 15 or more 25 25 a. Complete the crosstabulation shown below. Green Condition Female Too Fast 10 Fine Fine 40 Female Golfers Total Green Condition Handicap Under 15 15 or more Too Fast 1 Fine 9 39 51 Total Which group shows the highest percentage saying that the greens are too fast? - Select your answer - b. Refer to the initial crosstabulations. For those players with low handicaps (better players), which group (male or female) shows the highest percentage saying the greens are too fast? For the low handicappers, the - Select your answer - have a higher percentage who…arrow_forwardThe U.S. Geological Survey monitors and reports on earthquakes, providing daily real-time, worldwide earthquake lists. Some of the information for four of the 105 earthquakes of magnitude 1.5 or greater that occurred on May 10, 2013, is shown in the following table. Magnitude is given on the Richter scale and NST stands for the number of stations that reported the activity on the same earthquake. Complete parts (a) through (e) below. Time Magnitude Depth (km) NST Region 00:03:16 1.7 75.9 29 Alaska 04:59:11 1.7 134.9 18 Alaska 08:27:04 2.8 64.0 21 Alaska 23:30:09 4.2 10.0 34 China a. Identify the type of data provided by the information in the first column of the table. Also identify the variable under consideration. Quantitative, Continuous, Qualitative, Quantitative, Discrete, region where the earthquake occurred depth of the earthquake in kilometers number of stations reporting the earthquake…arrow_forward
- Vince had 10 weeks to get in shape for a race. The line graph shows how many miles he ran per training session each week. 10-Week Training 7 6. 4 2 0 1 2 3 4 5 6 7 8 9 10 Week © 2020 StrongMind. Created using GeoGebra. What is the total number of miles that Vince ran per session in weeks 5, 6, 7, and 8? Enter your answer as a whole number, like this: 42 Milesarrow_forwardQ3 needed to be solved correctly in 30 minutes and get the thumbs up please show neat and clean workarrow_forwardFor each of the worksheets, Total Profit per Region and Sales per Month, decide which type of chart would best represent the data. Please be sure to discuss why you would choose these types of charts based on the data you would be visualizing.arrow_forward
- The r code for side by side boxplot of vitamind v newage and vitamin d v country. Scatterplot code for relationship between vitamin d level and age.arrow_forwardHelp me fast so that I will give Upvote.arrow_forwardRecently, management at Oak Tree Golf Course received a few complaints about the condition of the greens. Several players complained that the greens are too fast. Rather than react to the comments of just a few, the Golf Association conducted a survey of 100 male and 100 female golfers. The survey results are summarized here. Excel File: data02-31.xlsx Male Golfers Male Green Condition Handicap Under 15 15 or more 25 25 a. Complete the crosstabulation shown below. Green Condition Gender Too Fast Fine Female 35 40 Too Fast 10 65 60 Fine 40 Total 100 100 Female Golfers 200 Green Condition Handicap Under 15 15 or more Too Fast 1 Note: This exercise is an example of Simpson's Paradox. 39 Fine 9 Total 75 125 Which group shows the highest percentage saying that the greens are too fast? Females, at 40% b. Refer to the initial crosstabulations. For those players with low handicaps (better players), which group (male or female) shows the highest percentage saying the greens are too fast? For…arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Algebra for College StudentsAlgebraISBN:9781285195780Author:Jerome E. Kaufmann, Karen L. SchwittersPublisher:Cengage LearningElementary Geometry for College StudentsGeometryISBN:9781285195698Author:Daniel C. Alexander, Geralyn M. KoeberleinPublisher:Cengage LearningMathematics For Machine TechnologyAdvanced MathISBN:9781337798310Author:Peterson, John.Publisher:Cengage Learning,
Algebra for College Students
Algebra
ISBN:9781285195780
Author:Jerome E. Kaufmann, Karen L. Schwitters
Publisher:Cengage Learning
Elementary Geometry for College Students
Geometry
ISBN:9781285195698
Author:Daniel C. Alexander, Geralyn M. Koeberlein
Publisher:Cengage Learning
Mathematics For Machine Technology
Advanced Math
ISBN:9781337798310
Author:Peterson, John.
Publisher:Cengage Learning,