Skip to main content
Solved

ASCII to CSV

  • 15 November 2022
  • 4 replies
  • 328 views

wind

Hello,

How can I convert an ASCII file to xyz csv file please?

Thank you

Best answer by redgeographics

You could use a RasterCellCoercer to generate a point for every pixel and assign the band value as to an attribute automatically, then a CoordinateExtractor to get the x and y values too and write them out to a CSV file.

 

Alternatively, you may even get away with writing directly to a Point Cloud XYZ file.

View original

redgeographics
Celebrity
Forum|alt.badge.img+45

This is a very generic question. If you want a specific answer it would help if you could show us what your ASCII file looks like. Or do you mean an ASCII grid file?


wind
  • November 17, 2022

Hello,

 

this is the file I want to convert. It's an numeric terrain model each 1m. So I need to have an csv file with coordinates and elevation like this: 893798.5, 6256850.5, 314image.pngThank you!


redgeographics
Celebrity
Forum|alt.badge.img+45

You could use a RasterCellCoercer to generate a point for every pixel and assign the band value as to an attribute automatically, then a CoordinateExtractor to get the x and y values too and write them out to a CSV file.

 

Alternatively, you may even get away with writing directly to a Point Cloud XYZ file.


wind
  • November 17, 2022

It works!

Thank you very much


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings