python对逻辑回归进行显著性_python3二元Logistics Regression 回归分析(LogisticRegression)...

本文介绍了在Python中如何进行二元逻辑回归分析,强调了LogisticRegression模型的使用,包括statsmodels和sklearn库的实现。文章指出Logistic回归用于处理二分类问题,并解释了模型的基本假设和重要性,如截距项。通过代码示例展示了如何建立和评估模型,同时提到了在数据处理中可能出现的问题和解决方案。
摘要由CSDN通过智能技术生成

纲要

boss说增加项目平台分析方法:

T检验(独立样本T检验)、线性回归、二元Logistics回归、因子分析、可靠性分析

根本不懂,一脸懵逼状态,分析部确实有人才,反正我是一脸懵

首先解释什么是二元Logistic回归分析吧

二元Logistics回归 可以用来做分类,回归更多的是用于预测

981603-20181025165945439-1994423144.png

官方简介:

链接:https://pythonfordatascience.org/logistic-regression-python/

355a71f5db817c2bd3339a506415426e0e5.png

6b91c64baa76230d705428c34efb025e178.jpg

a823985279db721cf26b3b9ddf06354b8f1.jpg

Logistic regression models are used to analyze the relationship between a dependent variable (DV) and independent variable(s) (IV) when the DV is dichotomous. The DV is the outcome variable, a.k.a. the predicted variable, and the IV(s) are the variables that are believed to have an influence on the outcome, a.k.a. predictor variables. If the model contains 1 IV, then it is a simple logistic regression model, and if the model contains 2+ IVs, then it isa multiple logistic regression model.

Assumptionsforlogistic regression models:

The DViscategorical (binary)

If there are more than2 categories interms of types of outcome, a multinomial logistic regression should be used

Independence of observations

Cannot be a repeated measures design, i.e. collecting outcomes at two different time points.

Independent variables are linearly related to the log odds

Absence of multicollinearity

Lack of outliers

原文

981603-20181025162124496-668013181.png

理解了什么是二元以后,开始找库

需要用的包

这里需要特别说一下,第一天晚上我就用的logit,

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值