June 2017
Beginner to intermediate
576 pages
15h 22m
English
Here are some notes on the Python decision tree code which appears below.
For the first code chunk, notice the "magic" directive in the first line of the code. The magic directive begins with '%' and specifies which language or API you will be using. Therefore, since we will be using Python instead or R, we need to specify %python as the first line. That is because the notebook was originally set up as an R notebook. When mixing languages, you need to specify the language used as the first line, unless you are writing in the default notebook language.
For those of you who are not familiar with Python, the import directives at the top of the code import the needed libraries and modules, which are to be used by ...