- Python Machine Learning Blueprints
- Alexander Combs Michael Roman
- 297字
- 2021-07-02 13:49:36
The Jupyter Notebook
There are a number of libraries that will make the data inspection process easier. The first is Jupyter Notebook with IPython (http://ipython.org/). This is a fully-fledged, interactive computing environment, and it is ideal for data exploration. Unlike most development environments, Jupyter Notebook is a web-based frontend (to the IPython kernel) that is divided into individual code blocks or cells. Cells can be run individually or all at once, depending on the need. This allows the developer to run a scenario, see the output, then step back through the code, make adjustments, and see the resulting changes—all without leaving the notebook. Here is a sample interaction in the Jupyter Notebook:

You will notice that we have done a number of things here and have interacted with not only the IPython backend, but the terminal shell as well. Here, I have imported the Python os library and made a call to find the current working directory (cell #2), which you can see is the output below my input code cell. I then changed directories using the os library in cell #3, but stopped utilizing the os library and began using Linux-based commands in cell #4. This is done by adding the ! prepend to the cell. In cell #6, you can see that I was even able to save the shell output to a Python variable (file_two). This is a great feature that makes file operations a simple task.
Now, let's take a look at some simple data operations using the notebook. This will also be our first introduction to another indispensable library, pandas.
- 電腦常見問題與故障排除
- SDL Game Development
- 硬件產(chǎn)品經(jīng)理手冊:手把手構(gòu)建智能硬件產(chǎn)品
- Unity 5.x Game Development Blueprints
- 筆記本電腦維修不是事兒(第2版)
- 微軟互聯(lián)網(wǎng)信息服務(wù)(IIS)最佳實踐 (微軟技術(shù)開發(fā)者叢書)
- Building 3D Models with modo 701
- 深入理解序列化與反序列化
- 微型計算機系統(tǒng)原理及應(yīng)用:國產(chǎn)龍芯處理器的軟件和硬件集成(基礎(chǔ)篇)
- 單片機開發(fā)與典型工程項目實例詳解
- VMware Workstation:No Experience Necessary
- 數(shù)字媒體專業(yè)英語(第2版)
- 基于PROTEUS的電路設(shè)計、仿真與制板
- Spring Cloud實戰(zhàn)
- 單片機原理及應(yīng)用