GLORY Posted 23 hours ago Posted 23 hours ago Hello Everyone, I need some help; here is my list in csv 1,21.188,19.762,0.000,L1S 2,31.804,7.629,0.000,L2S 3,44.106,18.077,0.000,L2 4,32.984,30.378,0.000,L1 5,45.117,40.995,0.000,L1 6,56.239,26.671,0.000,L2 7,68.878,36.782,0.000,L2E 8,57.587,50.937,0.000,L1E 9,49.168,65.549,0.000,L1S 10,43.612,72.164,0.000,L1 11,50.491,77.059,0.000,L1 12,55.253,70.179,0.000,L1C 13,41.363,59.993,0.000,L2S 14,34.616,68.460,0.000,L2 15,27.472,64.094,0.000,L2 16,33.954,55.495,0.000,L2C And I want to make that list into something like this, (setq pt (list (nth 1 ln) (nth 2 ln) (nth 3 ln))) (setq mylist '( (("L1S" (list pt)) ("L1" (list pt))...("L1E" (list pt))) (("L2S" (list pt)) ("L2" (list pt))...("L2E" (list pt))) (("L1S" (list pt)) ("L1" (list pt))...("L1C" (list pt))) (("L2S" (list pt)) ("L2" (list pt))...("L2C" (list pt))) ) ) In order to plot the lines into groups by creating another set of group of points if the description has "S" or start at the end, say L1S for Line 1 Start. Thank you in advance.Line1 and 2 Group List.csv Quote
devitg Posted 18 hours ago Posted 18 hours ago @GLORY Please upload a sample.dwg as you need it to be, at least 2 lines Quote
BIGAL Posted 12 hours ago Posted 12 hours ago Ok that is what you get in field survey using Total stations, GPS etc so you want to string the description. Yes I have something, working on it for Bricscad. I have spent over 45+ years doing civil work, so can see what you want, the simple answer is CIV3D or Civil Site Design or Carlson, etc that is civil software, When reading a points file it will string the points via a description, add blocks matching descriptions and more. I am working on the add blocks and line work on correct layer. Your csv processed. Happy to discuss further. But I don't intend to reinvent the wheel to much. Quote
GLORY Posted 2 hours ago Author Posted 2 hours ago Sorry guys for the late reply. @devitgHere is an example of the drawing processed by the code I've been trying to work on for a while now. But it can only handle 2-Description at a time, either a combination of two different lines or a line and block combo. Let say, “L1E/L2S” or “L1S/BP” which is a point block and can no longer TRIGGER to read 3-Description csv line like “L1E/L2S/BP”, this kind of description can only plot the “BP”, it will not plot the "L1" lines calling “L1E” (the trigger) to plot L1 Group then start collection of L2 point groups. But upon checking the group list say for L1, the points are there inside that list but cannot trigger to plot the L1 group of points into lines since BP is already called in the first condition of the code. This is the reason I want to change the point collection list into groups and process the line list groups after reading all the lines in the csv. @BIGAL, thank you for your response. I also work in Civil 3D to process these kinds of data. The only problem is that you need to export it in plain AutoCAD format to arrange all the annotation etc., cause COGO are not easy to handle. Say aligning the annotation for block points to be aligned to lines or move it into desired location. Line1 and 2 Group List.dwg Quote
devitg Posted 36 minutes ago Posted 36 minutes ago 1 hour ago, GLORY said: This is the reason I want to change the point collection list into groups and process the line list groups after reading all the lines in the csv. @GLORY As I can get ,there are same point with same identifier (last text at csv line) Mybe you can add some new identification to group by it at same CSV Like this 1,21.188,19.762,0.000,L1S,pl1.1 4,32.984,30.378,0.000,L1,pl1.2 5,45.117,40.995,0.000,L1,pl1.3 8,57.587,50.937,0.000,L1E,pl1.4 2,31.804,7.629,0.000,L2S,pl2.1 3,44.106,18.077,0.000,L2,pl2.2 6,56.239,26.671,0.000,L2,pl2.3 7,68.878,36.782,0.000,L2E,pl2.4 9,49.168,65.549,0.000,L1S,pl3.1 10,43.612,72.164,0.000,L1,pl3.2 11,50.491,77.059,0.000,L1,pl3.3 12,55.253,70.179,0.000,L1C,pl3.4 13,41.363,59.993,0.000,L2S,pl4.1 14,34.616,68.460,0.000,L2,pl4.2 15,27.472,64.094,0.000,L2,pl4.3 16,33.954,55.495,0.000,L2C,pl4.4 Or state in a new csv which order belong to each polyline Say Quote PL1 1 4 5 8 Pl2 2 3 6 7 Pl3 9 10 11 12 Pl4 13 14 14 16 Line1 and 2 Group List- oredr + idfier.dwg Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.