Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Complete this assignment in an R Markdown document. Well use the mpg dataset that comes with ggplot2 package. Note: Be sure that you have installed

Complete this assignment in an R Markdown document. Well use the mpg dataset that comes with ggplot2 package. Note: Be sure that you have installed and attached the ggplot2 pacakage. This is easily done by installing and attaching the tidyverse package. Call this dataset mpg and import into your environment with the code chunk below:

mpg = ggplot2::mpg

Show all R code in code chunks.

Q1 How many rows and columns are in this dataset?

Q2 Plot city gas mileage (cty variable) versus highway gas mileage(hwy). Use geom_point. Describe the relationship between these two variables.

Q3 Plot city gas mileage (cty variable) versus highway gas mileage(hwy) and facet on the class variable. Use geom_point. Comment on the relationships in these plots.

Q4 Plot city gas mileage (cty variable) versus the cylinders (cyl) variable. Use geom_point. Comment on the appropriateness of the choice of using a scatterplot for this plot.

Q5 Use knitr::kable to create a table of the first 10 rows AND first 5 columns of the dataset.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Logics For Databases And Information Systems

Authors: Jan Chomicki ,Gunter Saake

1st Edition

1461375827, 978-1461375821

More Books

Students also viewed these Databases questions

Question

Show algebraically that b 2 n1Pni 1(Xi )2 (Xn )2.

Answered: 1 week ago

Question

Is it clear what happens if an employee violates the policy?

Answered: 1 week ago