• Lab 1: This lab will introduce you to using the AUX, FILES, STATUS, HEADER, FNAME and DATALIST commands.
    • What you need to do:
      1. Use the WAVEFORM or HEADER/CREATE command to force a file called myfile.tmp to be created in your home directory.
      2. If it is not already on your read AUX list, put HOME on it. Now run the command:
        nM> waveform myfile.tmp ELEM=8k
        Where was the file created?
      3. Use the FILES command to find the name of the shape (.shp) file that is located in the dat area of SYS.
      4. Use the STATUS command to find out the size (number of bytes) of the shape file in the dat area of SYS.
      5. Use DATALIST to list the data in airports.csv.
      6. Now use STATUS with the /d switch to list the header and data in airports.csv. But, this time, give it the HEADERROWS=1 qualifier, and see what happens.
      7. Set up an AUX called WEB and point it to http://nextmidas.techma.com/nm/nxm/sys/dat/. Now list the header of the world.prm in this AUX.
      8. Use the HEADER command to create the similarly named files called temp_xxx_file.tmp, temp_yyy_file.tmp, temp_xyx_file.tmp, and temp_zzy_file.tmp. Then use the FILES command to find all files starting with temp_, with a y somewhere after the temp_ and ending with _file. Use the FILES/E command to erase all of the files you created.
      9. Use FNAME to form the path for the DAT area of the SYS option tree.
      10. Use FILE to open the airports.csv file, convert it into a table with a row prefix of R_ excluding the header, then close the file. Hint: Use QUERY to find appropriate operation (e.g. toTable) to use on the CsvFile.
    • Hints:
      • Before using airports.csv, take a look at the API for the CsvFile class. It has a good explanation about the HEADERROWS= qualifier.