目录 机器学习入门············································································1 机器学习简介 ···········································································1 1.1.1 什么是机器学习································································1 1.1.2 机器学习的前景································································2 机器学习的主要类型 ··································································3 1.2.1 监督学习·········································································4 1.2.2 无监督学习······································································5 1.2.3 半监督学习······································································7 1.2.4 强化学习·········································································8 1.2.5 监督学习案例································································.10 选择正确的算法·····································································.12 机器学习工具和环境·································································14 Python 介绍···········································································.14 2.1.1 Python 的安装 ·······························································.14 2.1.2 Python 基础语法 ····························································.19 2.1.3 Python 其他特性 ····························································.24 2.1.4 Python 简单实战案例(猜字游戏) ····································.31 2.1.5 Python **实战案例(网络爬虫) ····································.35 数据科学库···········································································.38 2.2.1 NumPy ········································································.38 2.2.2 Pandas ·········································································.45 2.2.3 数据科学库案例(电商网站) ··········································.54 机器学习库···········································································.55 2.3.1 Scikit-Learn···································································.55 2.3.2 TensorFlow ···································································.60 2.3.3 Keras···········································································.64 2.3.4 机器学习库案例(预测糖尿病) ·······································.67 数据预处理·············································································70 数据导入 ··············································································.70 数据清洗 ··············································································.71 特征工程 ··············································································.73 3.3.1 特征选择······································································.73 3.3.2 特征转换······································································.75 3.3.3 特征缩放······································································.77 数据分割 ··············································································.78 3.4.1 训练集·········································································.78 3.4.2 测试集·········································································.79 3.4.3 验证集·········································································.80 案例分析:银行客户数据·························································.80 机器学习模型的构建与评估························································84 监督学习实战········································································.84 4.1.1 线性回归······································································.84 4.1.2 逻辑回归······································································.86 4.1.3 决策树·········································································.88 4.1.4 随机森林······································································.90 无监督学习实战·····································································.91 4.2.1 K-means ·······································································.92 4.2.2 主成分分析···································································.93 深度学习实战········································································.95 4.3.1 神经网络······································································.95 4.3.2 卷积神经网络··············