今天正式开始上Statistical Machine learning。 需要配置Python
https://conda.io/docs/user-guide/getting-started.html
下一步还需要做
- review numpy, matplot, pandas.
Conda Overview
The conda
command is the primary interface for managing installations of various packages. It can
- Query and search Anaconda package index and current Anaconda installation.
- Create new conda environment.
- Install and update packages into existing conda environments
Conda environments
A conda environments is a directory that contains a specific collection of conda packages that you have installed
- e.g. you may have one environment with NumPy 1.7 and its dependencies, and another environment with NumPy 1.6 for legacy testing. If you change one environment, your other environments are not affected
- You can easily activate or deactivate environments, which is how you switch between them.
conda install [packagename]
to install conda packages
【坑】
Jupyter notebook ---when importing external .py classes, one has either to reload the class OR restart IPython kernel ---- when the source file is modified.
initializing dumpy array : note there is no way to initialize an array without filling it with something. i.e it is illegal to initialize an array (like what we do in java or cpp)
a = np.array((3,4)) #array of shape(3,4)
instead, one has to usea = np.zeros((3,4))
ora = np.zeros([....])
from existing data https://docs.scipy.org/doc/numpy-1.13.0/reference/routines.array-creation.html