Question

How to write a file for each distinct value?


I'm processing LIDAR data against NYC BBLs(a unique number for each lot). The BBLs are in a shapefile and I'm checking intersections between the elevation points and the BBLs. After I've intersected the points and added in the BBL to which they belong. I want to output a file for each distinct BBL that has the points inside it.

Could anyone provide guidance?


3 replies

Badge

Hello @khickmanperfett,

Sounds like you want to do a 'fanout'. The LIDAR writer is 'folder-based', so the output feature type name will be the file name. Open the output feature type, and under the General tab, click on the down-arrow at the end of the 'LAS File Name' box, and select the BBL attribute. If you want to get fancy, you can try using the "Open Text Editor" option.

More information here:

https://knowledge.safe.com/articles/565/fanout-1.h...

Regards,

Ryan

@RyanAtSafe The lidar data is in a csv format of lat, lng, elevation and I'm planning on outputting it as a series of csvs. I was hoping to be able to have the csvs named after the bbl of the points that have passed through the filters.

Userlevel 2
Badge +17

Hi @khickmanperfett, you can create points based on the lat/lon attributes using the VertexCreator and then clip them by the BBL areas using the Clipper.with 'Merge Attributes' option. Since the points output from the 'Inside' port will have the lot number attribute of a spatially related BBL, you can configure destination feature type name (i.e. CSV file name) in the writer feature type properties using the lot number.

Reply