Correct me if I'm wrong, but I heard that Logistic Regression takes the Linear Regression of the data as a "variable" (instead of x), such that:
Is it true? cause for the code below I got different coefficients for the same data:
data = pd.read_csv('logistic_reg.csv')
scores = data['score']
states = data['approved']
x = np.array(scores).reshape(-1,1)
y = np.array(states)
model = LinearRegression().fit(x,y)
print(model.coef_)
print(model.intercept_)
model = LogisticRegression().fit(x,y)
print(model.coef_)
print(model.intercept_)
[0.00270938]
-1.050025042121259
[[0.04209124]]
[-23.95021449]
Thanks for your answers.