Determining if rounded points form a line

#1

I have a large data set where I am trying to determine whether the points form lines within a specified tolerance (1/16").

Here I have a set of lines.

50%20PM

I drew a line between the end points, offset each side by 1/16" and closed offsets to create a boundary box. Using SelBoundary shows that all the points are inside the box and are within the tolerance. Thus they form a line within 1/16".

Is there any way to do this rapidly?

If I create a spline through the points, then CONVERT with a tolerance of 1/16" I get two lines. So that’s not working out here.

Problem Tolerance.3dm (3.1 MB)

0 Likes

(Pascal Golay) #2

Hello - I don’t know if this is what you need but just in case - it asks for a max deviation and points - if it can calculate a line from those points from which no point is farther than max deviation, it will create the line…

To use the Python script use RunPythonScript, or a macro:

_-RunPythonScript "Full path to py file inside double-quotes"

LineFromPoints.py (2.6 KB)

@bigjimslade - I monkeyed with it a little more - more granular options for when to add the line or just tell you about it.

-Pascal

0 Likes

#3

Thanks, this serves the purpose that I was going for.

0 Likes

#4

One way to improve this would be to ignore selected objects other than points. Now, if you select points and a curve it pukes.

0 Likes

(Pascal Golay) #5

Yep, sorry. . Haste making waste…Updated above

-Pascal

0 Likes