Hello everyone and welcome to the coral Plath's maps exercises lecture and this lecture we're going
to briefly go over the notebook for the choral Plath's maps exercise.
Let's go ahead and Jump's that you put a notebook now.
All right here we are at the coral Pless maps exercise notebook.
In this exercise we're going to give you some rather simple datasets and to create correlate maps from
them using the plot the library.
Now unfortunately due to the nature of slightly the fact that there HCM elf files you can't actually
see the example display output here centrally is just going to look like a blank output for both the
global map on the world scale and also the USA chloroplast map.
There's just going to be essentially blank outputs so you can actually compare unless you run the solutions
.
No but what it should look like.
But the data sets themselves are relatively simple enough.
They should have an idea of what you want to output your imports are already set up for as far as your
plotless imports you're going to go ahead and import pandas and read the CAC file.
Your first one is going to be 2014 world power consumption you're going to go out and check the head
of the data frame it should look like this.
And then using the lecture notes and using the documentation which you're going to go ahead and do is
create a core uplift plot of the power consumption for countries using a data and lay out dictionary
and then you should be able to essentially run these two lines of code like we did in the lectures.
And basically the only thing you have to do is set up data and lay out correctly.
Now that's the hardest part.
And as we've said before the syntax is pretty strange.
So I don't expect you to be able to do this off the top your head at all.
What you should be doing is referencing the documentation and the lecture and then filling in the blanks
to actually map this data to a coral clef map of the world's power consumption.
Then once you're done with that you're going to go and import some election data from 2012 as a CSP
file using Pandurs.
You'll go ahead and check the head of the data frame.
They'll look like this has a little bit more information but you're going to go ahead and do is create
a plot that displays the voting age population or a P per state.
And if you scroll over to the right here.
Here it is.
Voting age population V.I.P.
Note that this is a float.
So it's already been converted from a string.
So these other columns are actually strings but this one is already converted to a float for you so
it should work fine.
And it actually mentions this here a few later want to clear out the other columns.
Make sure you consider their data type and they've already been transformed for you.
You're going to go ahead and just set up data and lay out dictionaries and then hopefully run this line
and be able to plot this.
Again this is more of an exercise of you being able to take what you already know and documentation
and references that you've already seen and fill in your data to that sort of documentation and formatting
.
This is not an exercise in having everything memorized and being able to create a data and lay out dictionary
from scratch.
Really that's just unrealistic.
And you'll have to usually reference the documentation for these sort of plots.
All right.
Hope you enjoy the exercise should be pretty straightforward.
Remember to just reference to lecture notebooks and if you ever get stuck you can also reference the
solutions lecture.
Coming up next.
Thanks everyone and I'll see you at the next lecture