吴裕雄 python 机器学习——数据预处理标准化MaxAbsScaler模型
from sklearn.preprocessing import MaxAbsScaler #数据预处理标准化MaxAbsScaler模型
def test_MaxAbsScaler():
X=[[1,5,1,2,10],
[2,6,3,2,7],
[3,7,5,6,4,],
[4,8,7,8,1]]
print("before transform:",X)
scaler=MaxAbsScaler()
scaler.fit(X)
print("scale_ is :",scaler.scale_)
print("max_abs_ is :",scaler.max_abs_)
print("after transform:",scaler.transform(X)) # 调用 test_MaxAbsScaler
test_MaxAbsScaler()
吴裕雄 python 机器学习——数据预处理标准化MaxAbsScaler模型的更多相关文章
- 吴裕雄 python 机器学习——数据预处理标准化StandardScaler模型
from sklearn.preprocessing import StandardScaler #数据预处理标准化StandardScaler模型 def test_StandardScaler() ...
- 吴裕雄 python 机器学习——数据预处理标准化MinMaxScaler模型
from sklearn.preprocessing import MinMaxScaler #数据预处理标准化MinMaxScaler模型 def test_MinMaxScaler(): X=[[ ...
- 吴裕雄 python 机器学习——数据预处理正则化Normalizer模型
from sklearn.preprocessing import Normalizer #数据预处理正则化Normalizer模型 def test_Normalizer(): X=[[1,2,3, ...
- 吴裕雄 python 机器学习——数据预处理流水线Pipeline模型
from sklearn.svm import LinearSVC from sklearn.pipeline import Pipeline from sklearn import neighbor ...
- 吴裕雄 python 机器学习——数据预处理字典学习模型
from sklearn.decomposition import DictionaryLearning #数据预处理字典学习DictionaryLearning模型 def test_Diction ...
- 吴裕雄 python 机器学习——数据预处理过滤式特征选取SelectPercentile模型
from sklearn.feature_selection import SelectPercentile,f_classif #数据预处理过滤式特征选取SelectPercentile模型 def ...
- 吴裕雄 python 机器学习——数据预处理过滤式特征选取VarianceThreshold模型
from sklearn.feature_selection import VarianceThreshold #数据预处理过滤式特征选取VarianceThreshold模型 def test_Va ...
- 吴裕雄 python 机器学习——数据预处理二元化OneHotEncoder模型
from sklearn.preprocessing import OneHotEncoder #数据预处理二元化OneHotEncoder模型 def test_OneHotEncoder(): X ...
- 吴裕雄 python 机器学习——数据预处理二元化Binarizer模型
from sklearn.preprocessing import Binarizer #数据预处理二元化Binarizer模型 def test_Binarizer(): X=[[1,2,3,4,5 ...
随机推荐
- ubuntu set up 3 - cuda
https://www.pugetsystems.com/labs/hpc/How-to-install-CUDA-9-2-on-Ubuntu-18-04-1184/ How to install C ...
- PHP实现推送微信小程序模板消息
这边只会写如何实现,至于在公众号管理后台添加模板消息可以参考这篇文章: https://www.cnblogs.com/txw1958/p/wechat-template-message.html,当 ...
- DOM操作节点对象集合
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/stri ...
- Mysql部分存储引擎介绍
Mysql存储引擎 什么是存储引擎 mysql中建立的库 --> 文件夹 库中建立的表 --> 文件 现实生活中我们用来存储数据的文件有不同的类型,每种文件类型对应各自不同的处理机制: ...
- 百度地图和echarts结合实例
1.由echart对象(bmapChart)获取百度地图对象(bdMap),echart对象(bmapChart)适用于所有的echart的操作和接口,百度地图对象(bdMap)适用于百度地图的所有接 ...
- FPM 0.08不能运行破解办法……
FPM_0.080.rar 破解办法:用UltraEdit打开FPM.exe,查找"33 C0 E9 F2"(注意中间有空格)将33改为8B,F2改为00
- Python记:列表方法略记
- 使用Powershell开机启动隐藏窗口的程序
1.打开注册表找到键值:计算机\HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run 2.添加字符串值:StartJetSer ...
- CBE引擎概览
摘录于CBE官方文档:https://www.comblockengine.com/docs/1.0/overview/index/ 架构图总览: Switch Fabric:交换机网络,根据网络环境 ...
- 搭建Python开发环境(Mac)
准备 Python官网: https://www.python.org/ Python官方文档: https://docs.python.org/ 环境搭建 简介 pipenv是Python官方推荐的 ...