Altering elevation values for an ASCII export

Greetings, I am trying to export an arc ascii grid but prevent values outside of a predetermined min and max from being passed on. Here is what I have so far:

GLOBAL_MAPPER_SCRIPT VERSION=1.00


//import ASCII data and ignore all values outside of the -5 to -65 range
IMPORT FILENAME="TG_004_BKSC_Caris.asc" \
TYPE=ARCASCIIGRID INC_ELEV_COORDS=YES MIN_ELEV='-5' MAX_ELEV='-65'

 // export the file as imported - ignoring the values less than -5 and greater than -65
EXPORT_ELEVATION FILENAME="C:\Users\surve\Desktop\Mike Reed\GM_scripts/Caris_test.asc" \
TYPE=ARCASCIIGRID GEN_PRJ_FILE=YES


The exported ASCII file includes all data and does not ignore the values outside of the bounds I have tried to set

Best Answer

  • bmg_bobbmg_bob Global Mapper Programmer Posts: 1,960
    Answer ✓
    Hello,

    The easiest way to get a good IMPORT command is to have Global Mapper do it for you as follows:
    1. Load your data into Global Mapper
    2. Use the Elevation Options | Alter Elevation Values tab to set the Maximum Valid Elevation and Minimum Valid Elevation
    3. Save a workspace
    4. Open the workspace file in a text editor such as Notepad.
    5. Copy the IMPORT command (you will likely also want the DEFINE_PROJ ... END_DEFINE_PROJ lines also so you will have the correct projection information) to your script file.
    Cheers,
    Bob
    mjreed12

Answers

Sign In or Register to comment.