0
$\begingroup$

I have a set of points in 3D (x,y,z). I ordered these points from the lowest to highest. So, I want to used linear regression to fit a line through these ordered points and then to find out a break point where the that exhibits the greatest residual occurs.

  • 0
    By "lowest to highest", are you referring to the $z$ coordinates?2011-04-26
  • 0
    Already in this simpler problem: http://math.stackexchange.com/questions/31047/optimization-problem-with-two-step-discontinuous-function, it turns out that there are local minima and you can't avoid examining all possible break points. I suspect that will also be true in your case. If that is so, all you can do is to compute the required sums efficiently as you iterate over the possible break points (as described in my answer there).2011-04-26
  • 0
    yes i used Z coordinates to ordered my points.2011-04-26
  • 0
    yes joriki, all possible break points need to be check, since i am poor in mathamatics..could you explain me steps that i should follow2011-04-26
  • 1
    By the way, why do you want the greatest residual and not the smallest?2011-04-26
  • 0
    nice explanation joriki, but i guess i could not get it clearly since i am poor in this area. could you please explain it again with a numerical example?2011-04-26
  • 0
    @anh: please do not use answers to make comments.2011-04-26

1 Answers 1