python关联_Python-关联

python关联

python关联

Python-关联 (Python - Correlation)

Correlation refers to some statistical relationships involving dependence between two data sets. Simple examples of dependent phenomena include the correlation between the physical appearance of parents and their offspring, and the correlation between the price for a product and its supplied quantity.

相关性是指涉及两个数据集之间的相关性的一些统计关系。 相关现象的简单例子包括父母及其后代的外表之间的相关性,以及产品价格与其提供的数量之间的相关性。

We take example of the iris data set available in seaborn python library. In it we try to establish the correlation between the length and the width of the sepals and petals of three species of iris flower. Based on the correlation found, a strong model could be created which easily distinguishes one species from another.

我们以seaborn python库中可用的虹膜数据集为例。 我们尝试建立三种鸢尾花的萼片和花瓣的长度和宽度之间的相关性。 根据发现的相关性,可以创建一个易于将一个物种与另一个物种区分开的强大模型。


import matplotlib.pyplot as plt
import seaborn as sns
df = sns.load_dataset('iris')

 
#without regression
sns.pairplot(df, kind="scatter")
plt.show()


Its output is as follows −

输出如下-

corelation.png

翻译自: https://www.tutorialspoint.com/python_data_science/python_correlation.htm

python关联

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值