- Welcome to Python Fundamentals live lessons part two.
My name is Paul Deitel,
and I'll be your instructor for these live lessons videos.
Part two is based on chapters five through seven
of our textbook,
Intro to Python for Computer Science and Data Science.
Learning to program with AI, Big Data and the Cloud.
And chapters five through seven of Python for Programmers,
which is our professional book.
The prerequisite for part two of these live lessons videos
is Python Fundamentals, part one,
or equivalent Python programming experience.
Many people find that as they work their way
through the videos,
it's helpful to have a copy of the book at hand.
However, this is not required.
There is additional information in the books
that I don't cover as part of these videos.
If you're interested in getting a copy of one of the books,
you can find them in various print
and electronic formats at the sites that are listed for you.
If you're a college instructor,
you'll probably want to take a look
at Intro to Python for Computer Science and Data science,
which is our college textbook version of the book.
This one is in full color.
It's 880 pages, 240 pages more than Python for Programmers.
And in particular, it contains a ton of exercises.
557 self check exercises,
as well as 471 additional End-of-Chapter exercises
and projects.
Now many professionals find that they like
to work with the textbook version,
specifically because of the exercises.
If you're interested in learning more
about Intro to Python for Computer Science and Data Science,
please take a look at the links that I've provided below.
The first one is for an architectural diagram
in which we show you the four part modular structure
of this book,
and that really applies both the college textbook
and our professional book, Python for Programmers as well.
The For programmers book has one fewer chapter,
but the overall architecture of the two books is the same.
And also in the For programmers book,
we have less of the lower end pedagogical material,
that's really geared to people
who are novices in programming.
The second link is for the full table of contents
where you can see everything
that we're going to cover throughout the book.
And the third one is the books preface
where you can learn more about
our approach to teaching Python, Data Science,
Artificial Intelligence, and various Big Data topics.
I'd also like to recommend
that you take a look at these two additional links.
The first one is for the full book cover.
And in particular, if you look at the back cover copy,
you'll see a nice summary of everything
that we're going to do throughout these live lessons videos.
And I'd also recommend that you take a moment
to read through the technical
and academic reviewer testimonials,
to really get a sense of all the things
that they liked about
how we presented Python, and the various Data Science,
AI and big data topics.
Back in lessons three and four
of Python Fundamentals live lessons part one,
we started to introduce a couple of the key data structures
in Python, specifically lists and tuples.
And here in lesson five of part two,
we're going to take a look at those sequence data structures
in much more detail.
We'll talk about the various ways of creating
and manipulating both lists and tuples.
With respect to list,
we're going to show you some sorting
and searching capabilities that are built in.
We're also going to go in-depth into a variety
of functional style programming capabilities,
both built into the language syntactically
via what are known as comprehensions,
and also via library functions called Filter,
Map and Reduce respectively.
For the first time,
we're going to introduce
a two dimensional list data structure.
And we're only going to show one example of that.
Because in reality
when you get into multi-dimensional data in Python,
it's almost always going to be implemented
in the context of the NumPy open source library,
which is the topic of lesson seven in part two here.
We'll also revisit simulation a little bit in this lesson.
And in particular, we're going to show you
how to visualize the results of a simulation,
in this case using the libraries called Matplotlib
and Seabourn.
Seaborne is actually built on top of Matplotlib
and simplifies many of its capabilities.
In lesson six, we'll continue our discussion
of Python's built in data structures
with dictionaries and sets.
And just like we do for lists and tuples,
we'll talk about the different ways of creating objects
of these types and manipulating them.
And that will include some functional style programming
in the context of this thing called comprehensions,
that we will first introduce in lesson five.
As part of lesson six in the intro to data science section,
we'll be talking once again
about visualizations implemented
with Matplotlib and Seabourn.
But in this case, we're going to do a dynamic animated,
die rolling simulation.
And one of the cool things about this particular example
is that it gives you a way
to really visualize the law of large numbers in action.
To finish off part two of these live lessons videos,
we'll take a look at lesson seven
on array oriented programming with NumPy.
Now NumPy is one of the most popular
Python open source libraries.
It's used extensively by other libraries.
Something like 450 of them are built on top of NumPy.
So a lot of the techniques
that I'm going to show you in this lesson,
will also apply to other libraries as well.
So for instance,
when we get to the intro to data science section
at the end of this lesson,
we will introduce the Pandas library,
which also is built on top of NumPy.
So a lot of what you see earlier in this lesson,
will also apply to Pandas as well.
Throughout this lesson
we'll do some of the same types of things
that we did with Python's built in data structures.
We'll show you various ways of creating NumPy arrays.
We'll manipulate them lots of different ways.
And one of the things that you're going to see
with NumPy arrays is that you do a tremendous amount
of functional style programming.
So there's a concept
that's built into NumPy called broadcasting
that allows you for instance,
to take a NumPy array which could be millions
or billions of elements and multiply every element by two.
And the expression that you use to write that,
looks just like a regular arithmetic expression,
but somehow NumPy behind the scenes,
can parallelize that operation
and do it extremely efficiently.
So one of the key things with NumPy is its performance.
And we will actually do performance comparisons
to show you that NumPy can be up to 100 times faster
than doing similar operations
on Python's built in list data structure.
We're going to show you by the way,
both one dimensional NumPy arrays
and multi dimensional NumPy arrays.
And as we move into the intro to data science section
of this lesson,
we'll be focusing on the Pandas library,
which is built on top of NumPy.
So a lot of what I showed you earlier in the lesson,
will also apply in the context of Pandas.
What Pandas does though,
is it gives you even more capabilities.
And in particular,
you'll frequently use Pandas in subsequent lessons
to do things like,
load data into your system for analysis,
prepare the data for analysis,
get to know the data
by doing things like calculating descriptive statistics,
or doing basic graphing of the data as well.
So here we'll just start
to introduce the functionality of the Pandas library
and its two key data structures series
which are one dimensional,
and data frames, which are two dimensional.
And then we'll continue that discussion
in subsequent intro to data science sections in part three,
and we'll use Pandas a lot in the later lessons as well.