I have homework for (BUS-310 -A & B) Introduction to Business Analytics

Mikey77
Assignment7GraphicalAnalysis.R

# Open the Assignment 6 word file on BB and copy and paste your graphs in this document # After you finish answering all questions, Upload the word file on BB # Make a folder Assignment 6 # Download statedata.csv dataset and variables document from the BB # Save the two files in that folder # Set working directory # Read the dataset into R session and name it as state state = read.csv("statedata.csv") # Run the str function and take note of the quantitative and categorical variable str(state) # 1. Make a histogram of Population variable using hist function # 2. Color the above histogram yellow, increase number of breaks to 25 # 3. In the above histogram, add x label = Population, # main = Distribution of State Population # Describe the distribution: Is it symmetric, right skewed, or left skewed? # 4. Make a Bar graph to show the distribution of state.region variable # 5. Customize the above bargraph and color the bars red, blue, green, and yellow # 6. Scatterplot of Murder (y-axis) vs Frost (x-axis) # 7. Customizing the scatterplot in #6, x label = Frost, y label = Murder # main = Murder vs Frost # Is the form (linear or nonlinear), direction (positive or negative), # strength (strong or weak)? # 8. Scatterplot matrix of Population + Income + Illiteracy + Life.Exp + Murder # HS.Grad + Frost + Area # Life.Exp has negative relationship with which two variables? # Illiteracy has positive relationship with which variable? # 9. make boxplots to compare distribution of HS.Grad across state.region # 10. Color the above box plot red, blue, green, and yellow # 11. Add x label as Region, Y label as High School Graduation, and # main as High School Graduation across Regions # Which region has the highest median graduation rate? # Which region has the lowest median graduation rate? # 12. Add varwidth = T in the above boxplots to display difference in number of observations