开发者

Python or SQL Logistic Regression

开发者 https://www.devze.com 2023-01-17 01:52 出处:网络
Given time-series data, I want to find the best fitting logarithmic curve. What are good libraries for doing this in either Python or SQL?

Given time-series data, I want to find the best fitting logarithmic curve. What are good libraries for doing this in either Python or SQL?

Edit: Specifically, what I'm looking f开发者_如何学Goor is a library that can fit data resembling a sigmoid function, with upper and lower horizontal asymptotes.


If your data were categorical, then you could use a logistic regression to fit the probabilities of belonging to a class (classification).

However, I understand you are trying to fit the data to a sigmoid curve, which means you just want to minimize the mean squared error of the fit.

I would redirect you to the SciPy function called scipy.optimize.leastsq: it is used to perform least squares fits.

0

精彩评论

暂无评论...
验证码 换一张
取 消