9833 Rate this article: 5.0 How can I import a DEM in ASCII X, Y, Z format into ENVI? If you have a Digital Elevation Model (DEM) in an ASCII format, it can sometimes be a bit tricky to figure out the best way to import this file into ENVI. A DEM image can be stored as an ASCII file in a raster arrangement. This type of file can be read directly into ENVI using the generic ASCII image reader (File->Open External File->Generic Formats->ASCII). However, DEM data can also be stored as point data in an ASCII file. The DEM can have this ASCII point format: ID#, X, Y, Z This type of DEM file has four columns of data, consisting of the ID number, the X location, the Y location, and the Z data value. These points are usually an ASCII file; however, the File->Open External File->Generic Format->ASCII method in ENVI doesn't allow for the import of an ASCII file in this format, because it is an ASCII raster reader and is not meant to read ASCII point data. This Help Article describes how to import an ASCII DEM file stored as point data into ENVI. If you have a DEM ASCII file with the format of ID#, X, Y, Z, you can import this file into ENVI using the Topographic->Rasterize Point Data utility. Here is a sample data file in this format: 1, -107.7840409, 44.28326903, 366.2 2, -107.7764449, 44.28345405, 225.2 3, -107.7688487, 44.28363857, 309.2 4, -107.7612525, 44.28382258, 608.7 5, -107.7536563, 44.28400609, 600.2 This file shows 5 DEM locations and the associated data value. The first column is the ID number for each data value/location combination. The second column of data is the longitude value and the third column is the latitude value. The fourth column is the Z data (elevation) value. The file can be delimited by space, comma, or tab. The file can also contain any optional header information, provided that the header is commented out with a semicolon (;). Here are the steps to import this file into ENVI: 1. From the ENVI Toolbox, select Terrain > Rasterize Point Data. In ENVI Classic, select Topographic > Rasterize Point Data 2. Select the DEM ASCII file 3. In the Input Irregular Grid Points dialog box, verify that your desired file is shown as the input file. 4. Set the X Position Column as column 2. 5. Set the Y Position Column as column 3. 6. Set the Z Data Value Column as column 4. If your data file's columns are in a different order than the example file shown above, please make sure to set the columns in Steps 4-6 appropriately. 7. Select your Input Projection of Points. In this example, the ASCII file's input projection is Geographic Lat/Lon, the datum is WGS-84, and the units are degrees. 8. Click OK. 9. In the Gridding Output Parameters dialog, select your Output projection. Here the input and output projections are the same, so the parameters are the same as in Step 7. 10. Select the type of interpolation using the arrow toggle button. 11. Select whether or not to extrapolate edges by using the Yes/No arrow toggle button. If extrapolation is selected, quintic extrapolation is used. 12. Enter X and Y output pixel sizes in the units that correspond to your projection type. 13. Select the Output Data Type. 14. Click OK. 15. In the Gridding Output Parameters dialog box, select the Output Filename or output to Memory. 16. Click OK. The DEM ASCII file is now loaded in the Available Bands List window. Note: The Rasterize Point Data utility uses Delaunay triangulation of a planar set of points. After the irregularly gridded data points have been triangulated, they are interpolated to a regular grid. You can use linear or smooth quintic polynomial interpolation. You can also select extrapolation for grid points outside of the triangulation area. The grid points are read from an ASCII file and different input and output projections are supported. You can read more about this function in ENVI's Online Help under "Rasterize Point Data." This Help Article is a workaround for CR # 22480. Please login or register to post comments. How can I import my GPS Points into ENVI Classic? Using CALL_EXTERNAL with the Cygwin environment