- Information
- AI Chat
Was this document helpful?
Exercises On Descriptive Statistics
Course: Experimental Course In Decision Support Modeling (BUS K579)
14 Documents
Students shared 14 documents in this course
University: Indiana University
Was this document helpful?
1
K579 SPRING 2017
EXERCISES ON DESCRIPTIVE STATISTICS
Exercise #1
1. Summarize the salary data using summary(). Then use describe from the psych
package. Compare the two methods.
2. What are the counts of men and women by rank? Also, compute the proportions of the
total number; column proportions; row proportions.
3. Draw a histogram for years of service. Add a density line in red.
4. Draw a box plot for salary.
5. Draw a box plot for salary by rank. Make it horizontal.
6. Create a QQ plot of salary. What does the QQ plot tell you?
Exercise #2
1. Read the data set retaildata.csv into an object retail.
2. List the first few rows and last few rows of retail.
3. Plot age (x-axis) vs. credit score (y-axis).
a. Add title, "Customer Credit Score vs. Age".
b. Set the plot characters to filled circles; make the color red.
c. Label the x and y axes.
d. Set the limits of the x and y axes appropriately.
e. Draw lines on the graph at the mean age and the mean credit score. The lines
should be dark blue and dotted and of weight 1.25.
4. Count how many customers are under the average age and have lower than average
credit scores.