Instruction (80%)
Last updated
Last updated
下載課程內容: Download materials from unzip and remember the location of it on your computer
開啟jupyter notebook: 開啟cmd.exe (wins) 或terminal.app (osx),並輸入jupyter notebook
以啟動他。也可以打開Anaconda Navigator,然後選擇Jupyter notebook執行它。
啟動後命令視窗(cmd.exe或terminal.app)會出現一段有token的網址,請記得有這回事,當不小心關掉所有視窗後,只要用這段網址貼在網址列就可以重新打開jupyter notebook。
Shift + Enter
run the current cell, select below
Ctrl + Enter
run selected cells
Alt + Enter
run the current cell, insert below
Ctrl + S
save and checkpoint
Enter
take you into edit mode
D, D (press the key twice)
delete selected cells
Esc
take you into command mode
Y
change the cell type to Code
M
change the cell type to Markdown
A
insert cell above
B
insert cell below
建議jupyter notebook的使用者可直接改用jupyter lab,用法和jupyter notebook一樣,又可以讓存取檔案、操作資料變的更方便。打開Anaconda-Navigator就可以找到JupyterLab
或者直接在Command Line輸入jupyter lab就可以啟動。
啟動後的結果如下圖,編輯起來跟jupyter notebook一樣。
由於我建立這個gitbook的目的是授課,我提供以下學習材料,是我課堂中必要或者延伸教材。
Youtube的內容主要是沿著這個gitbook pyTutorial來講解,大部分的code都會和gitbook一樣,但gitbook可能會有一些章節內容有更新,Youtube則可能抽出一些額外單元獨立出來講(例如Sorting)。建議是跟著gitbook重頭打起,或者將github上這個repo複製到自己的電腦中。
: if與for的語法說明和使用以及AQI的案例說明
: 探索AQI資料(JSON)的內容結構
: 依照不同數值區間給予標籤,以空污為例
: 用for-loop找到一個list中的最大值
: 自己打造一個排序演算法:使用兩層的for-loop、if、調換Swap技巧、以及list和dict結構
設計教材的時候我習慣以案例為出發點來帶技術,所以我可能不會花很多時間去解釋例如資料型態、for或者if是什麼這樣的問題。因此我認為Datacamp是本課程最佳的輔助學習教材,他能夠透過互動的方式讓你了解基本的語法與操作。但是Datacamp的使用每個月是需要錢的,如果是課堂上的學生我們通常會幫忙申請教育版。以下這個網站把Datacamp的內容給複製到網頁外,可以速覽一下Datacamp上介紹Python基本語法的內容:
- Cover the interactive python tutorial of datacamp
Recommendation
Ebook on safari
Python document
Applied Text Analysis with Python: