Question
Question 1 (1 point) Listen We discussed three problems you can encounter with visualizations: aesthetic, substantive and ______? Question 1 options: perceptual usability overreliance on
Question 1 (1 point)
Listen
We discussed three problems you can encounter with visualizations: aesthetic, substantive and ______?
Question 1 options:
|
perceptual
|
|
usability
|
|
overreliance on visuals
|
|
oversimplification
|
Question 2 (1 point)
Saved
Listen
Basic descriptive statistics and visualizations should not be thought of as complimentary as they have nothing to do with each other.
Question 2 options:
True | |
False |
Question 3 (1 point)
Saved
Listen
By convention, the code we use to import Matplotlib is as follows:
import matplotlib as ___
Question 3 options:
Question 4 (1 point)
Listen
To run scripts from a notebook,
Question 4 options:
|
None of these
|
|
%matplotlib inline
|
|
%matplotlib
|
|
%run
|
Question 5 (1 point)
Listen
What method provides summary statistics for all numerical variables.
Question 5 options:
|
".describe"
|
|
".info"
|
|
".head"
|
|
".stats"
|
Question 6 (1 point)
Listen
Matplotlib has two interfaces, with one being based off of its connection to MATLAB, and the other off of Python's object-oriented approach
Question 6 options:
True | |
False |
Question 7 (1 point)
Listen
The MATLAB style interface creates an object
Question 7 options:
True | |
False |
Question 8 (1 point)
Listen
Which magic command would you run for interactive plots?
Question 8 options:
|
%matplotlib notebook
|
|
%matplotlib inline
|
Question 9 (1 point)
Listen
Complete the blank to write code that would save the figure you've created:
___.savefig('my_figure.png')
Question 9 options:
Question 10 (1 point)
Listen
What code would you use to set matplotlib's style to a style that will replicate a style from FiveThirtyEight.com?
Question 10 options:
|
plt.update.style('fivethirtyeight')
|
|
plt.style('fivethirtyeight')
|
|
plt.set.style('fivethirtyeight')
|
|
plt.style.use('fivethirtyeight')
|
Question 11 (1 point)
Listen
To display our matplotlib plot, we use
Question 11 options:
|
plt.display()
|
|
plt.dsp()
|
|
plt.show()
|
|
plt.view()
|
Question 12 (1 point)
Listen
Which magic command would you run for static images?
Question 12 options:
|
%matplotlib inline
|
|
%matplotlib notebook
|
Question 13 (1 point)
Listen
Unlike using matplotlib in a script, when running code in a notebook, you do not have to use plt.show() to get the plot to show.
Question 13 options:
True | |
False |
Question 14 (1 point)
Listen
What code would you use to change the tickmarks for the x axis?
Question 14 options:
|
plt.ticks.x([2,4,6])
|
|
plt.x_ticks([2,4,6])]
|
|
plt.set_xtick([2,4,6])
|
|
plt.xticks([2,4,6])
|
Question 15 (1 point)
Listen
Complete the code to change the x axis limits:
plt.____(0,5)
Question 15 options:
Question 16 (1 point)
Listen
You have `x` and `y` variables created and want to plot them on a line plot. Complete the code below:
ax.____(x, y)
Question 16 options:
Question 17 (1 point)
Listen
What code would you use to create a title for your plot?
Question 17 options:
|
ax.create_title('My Figure')
|
|
ax.set_title('My Figure')
|
|
ax.title('My Figure')
|
Question 18 (1 point)
Listen
Complete the blank to finish the code to turn off the grid for a plot:
plt.____(False)
Question 18 options:
Question 19 (1 point)
Listen
What argument would you use to change the size of a figure?
Question 19 options:
|
set_size()
|
|
You can't change the size. It is based on the size of your screen.
|
|
figsize()
|
|
size()
|
Question 20 (1 point)
Listen
To create a pie chart in Matplotlib, you must first calculate value counts of columns.
Question 20 options:
True | |
False |
Question 21 (1 point)
Saved
Listen
What method is used to sort the index?
Question 21 options:
|
rearrange_index()
|
|
sort()
|
|
sort_index()
|
|
sorted()
|
Question 22 (1 point)
Listen
Question 22 options:
To create a scatterplot with height on the x-axis, and weight on the y-axis, how would you complete the following?
Question 23 (1 point)
Listen
What is missing to complete a Matplotlib scatterplot?
Question 23 options:
Question 24 (1 point)
Saved
Listen
Question 24 options:
By convention, we import matplotlib pyplot as
Question 25 (1 point)
Saved
Listen
The `alpha` argument for the scatter plot instructs matplotlib how transparent or opaque you want your points to be.
Question 25 options:
True | |
False |
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started