Predict x,y coordinates by z value in point cluster

35 views Asked by At

i have point clusters in my point cloud and want to fit a line though these clusters along the highest density, to predict the x,y coordinate at a certain height. These clusters can mostly be described as "pole like objects" with noise and a slight slope.

On my search i mainly stumbled across multiple linear regression, but i got the feeling that they wont help solving this. Any ideas are much appreciated!

Example data:

x y z
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.3 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.3
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.8 5530846.3 256.2
360155.8 5530846.3 256.2
360155.9 5530846.4 256.2
360155.8 5530846.3 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.8 5530846.3 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.3
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2
360155.9 5530846.4 256.2

Solution: I am an idiot. Apparently i've made a mistake which led me to think the simplest solution would not work. But it does.

I simply use the linear regression from sklearn and use x,y coordiantes together as y and the height as x value in the regression. Works quite well in my case.

0

There are 0 answers