Course Content
Visualization in Python with matplotlib
Visualization in Python with matplotlib
Add Information to the Plot
Task
- Using the
.set()
function, perform the following:- set the x-axis label (
xlabel
) to'GDP per capita'
; - set the y-axis label (
ylabel
) to'Life expectancy'
; - set the plot title (
title
) to'GDP per capita vs life expectancy'
.
- set the x-axis label (
- Assign
fig.colorbar()
to thecbar
variable. - Set the colormap legend label to
'HDI'
(by applying the.ax.set_xlabel()
to thecbar
).
Switch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?
Thanks for your feedback!
Section 3. Chapter 12
Add Information to the Plot
Task
- Using the
.set()
function, perform the following:- set the x-axis label (
xlabel
) to'GDP per capita'
; - set the y-axis label (
ylabel
) to'Life expectancy'
; - set the plot title (
title
) to'GDP per capita vs life expectancy'
.
- set the x-axis label (
- Assign
fig.colorbar()
to thecbar
variable. - Set the colormap legend label to
'HDI'
(by applying the.ax.set_xlabel()
to thecbar
).
Switch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?
Thanks for your feedback!
Section 3. Chapter 12
Add Information to the Plot
Task
- Using the
.set()
function, perform the following:- set the x-axis label (
xlabel
) to'GDP per capita'
; - set the y-axis label (
ylabel
) to'Life expectancy'
; - set the plot title (
title
) to'GDP per capita vs life expectancy'
.
- set the x-axis label (
- Assign
fig.colorbar()
to thecbar
variable. - Set the colormap legend label to
'HDI'
(by applying the.ax.set_xlabel()
to thecbar
).
Switch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?
Thanks for your feedback!
Task
- Using the
.set()
function, perform the following:- set the x-axis label (
xlabel
) to'GDP per capita'
; - set the y-axis label (
ylabel
) to'Life expectancy'
; - set the plot title (
title
) to'GDP per capita vs life expectancy'
.
- set the x-axis label (
- Assign
fig.colorbar()
to thecbar
variable. - Set the colormap legend label to
'HDI'
(by applying the.ax.set_xlabel()
to thecbar
).
Switch to desktop for real-world practiceContinue from where you are using one of the options below
Section 3. Chapter 12
Switch to desktop for real-world practiceContinue from where you are using one of the options below