Thread: Q4) h(x) = ax
View Single Post
  #22  
Old 04-29-2013, 01:10 AM
vsuthichai vsuthichai is offline
Junior Member
 
Join Date: Jan 2013
Posts: 3
Default Re: Q4) h(x) = ax

Quote:
Originally Posted by Anne Paulson View Post
So, in this procedure we:

Pick two points;
Find the best slope a for those two points, the one that minimizes the squared error for those two points;
Do this N times and average all the as

Rather than:

Pick two points;
Calculate the squared error for those two points as a function of a;
Do this N times, then find the a that minimizes the sum of all of the squared errors, as we do with linear regression

Are we doing the first thing here or the second thing? Either way there's a simple analytic solution, but I'm not sure which procedure we're doing.
How do you solve for the minimum a that produces the least squared error?
Reply With Quote