Click here to Skip to main content
15,902,492 members
Please Sign up or sign in to vote.
4.20/5 (2 votes)
See more:
If anyone knows where i will get algorithms for linear regression & programs on data mining. I have to find out periodicity existing in shopping analysis & i have to find out error in periodicity of time ig. after purchasing one item approximately how many days another item got purchased.I have to find linear equation
y=ax+b.
f(x)=(24-x)/18*(sin(x)+1.5).
g(x)=f(x)/(ax+b).
It is a project of Cyclic model analysis on sequential patterns.(shopping project)if any link you know please give me.
Posted
Updated 20-Feb-11 3:55am
v2
Comments
Sandeep Mewara 19-Feb-11 23:49pm    
on Google?
Albin Abel 20-Feb-11 0:42am    
I am seeing this question second time. Google it, if couldn't find anything response back. I could give the algorithm for linear reg. But there is lot of codes available in net. If you don't understand them you ask specific questions

A basic statistics book gives you the steps. You can derive the algorithm from that steps too

Google is your friend: http://www.google.co.uk/search?sourceid=chrome&ie=UTF-8&q=algorithms+for+linear+regression[^]

Learn to use it: it is a lot quicker than asking a question.

Alternatively, look in any statistics book, and you will find the process outlined step-by-step.
 
Share this answer
 
Comments
Espen Harlinn 20-Feb-11 8:12am    
Right :)
Usually the method of least squares http://en.wikipedia.org/wiki/Least_squares[^] is good enough for linear regression.

Member 7685573s wrote:
f(x)=(24-x)/18*(sin(x)+1.5).
g(x)=f(x)/(ax+b).

What's the role of the above functions?
:)
 
Share this answer
 
Comments
Albin Abel 21-Feb-11 0:30am    
Yes, least squares are the principle behind regression. But it is needed to remove the colinearity if present in the variables before performing regression for precise results in real world application. He has to tell what accurate level of regression coefficients he wants to derive. My 5
Cost function: least squares
If you are using mat lab or a free version of matlab, you can utilize the cost function quite easily. Just make sure you have an instantaneous upstate for your function for every variance you test. You could also use the “normal function” if you don’t want to hard crack everything.
 
Share this answer
 
Comments
Patrice T 16-Mar-18 18:35pm    
you are 7 years too late.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900