Data Visualization with R | Week 1

Course link : https://www.coursera.org/learn/data-visualization-r

These are answers for Data Visualization with R Week 1

Practice Quiz – 1

1. Which chart is a type of correlation chart?

Scatterplot

Bar chart

Pie chart

Histogram


2. Which R statement creates a chart object based on the data frame “salesdata”, but allows you to vary the aesthetics from one layer to another?

ggplot(salesdata)

ggplot()

qplot()

ggplot(salesdata, aes(x = feature1, y = feature2))


3. True or False: The qplot() function has no defaults so you have more control over the output.

True

False


These are answers for Data Visualization with R Week 1

Graded Quiz – 1

1. Which R packages will this course use to create data visualizations? Select two answers.

Leaflet

ggplot2

qplot

None, you will use base R


2. Which chart is a type of part to the whole chart?

Bar chart

Stacked bar chart

Horizontal bar chart

Grouped bar chart


3. Which ggplot2 function can create a complete plot given the data, mappings, and geom as parameters?

ggplot2()

qplot()

geom()

ggplot()


These are answers for Data Visualization with R Week 1

Practice Quiz – 2

1. True or False: Numeric data can be qualitative or quantitative.

True

False


2. Which of the following statements about histograms is true? Select two answers.

A histogram divides data into bins and then counts the number of times a data point falls into each bin.

A histogram counts the frequency of each individual number in the data set.

A histogram displays quantitative data, while a bar chart displays qualitative data.

A histogram displays qualitative data, while a bar chart displays quantitative data.


3. Complete the sentence: A pie chart is the same as a ___________________________ in polar coordinates.

Grouped bar chart

Bar chart

Horizontal bar chart

Stacked bar chart


These are answers for Data Visualization with R Week 1

Graded Quiz – 2

1. Which parameter of the qplot() function changes the border color of the bars in a bar chart to blue?

border = I(“blue”)

colour = I(“blue”)

outline = I(“blue”)

fill = I(“blue”)


2. How can you improve the smoothness of a histogram?

Changing the number of bins has no impact of the smoothness of the histogram.

Reduce the number of bins to increase the bin width.

Always go with the default number of bins.

Increase the number of bins to reduce the bin width.


3. What step must you take before you can add the coord_polar() function to ggplot() to create a pie chart?

Add the geom_bar(position = “stack”) command to the ggplot() function.

Add the geom_bar(position = “dodge”) command to the ggplot() function.

Set the x argument of the aes() function used in the ggplot() function to the factor.

Add the geom_circle() command to the ggplot() function.



These are answers for Data Visualization with R Week 1

More in this line: https://progies.in/answers/summer-training-2022/data-visualization-with-r

Latest on Progies: –

The content uploaded on this website is for reference purposes only. Please do it yourself first.