Modify ASCII File Command

D_ModifyASCIIFile_600ppi Modify ASCII File


Command Licensing and Default Menu Location

  • The Modify ASCII File command is part of the RPS Tool Shed Toolbox
  • The command is located on the Tool Shed macros menu ribbon
  • The command is located in the Core menu group


Command Description

Utility to modify the contents of an Ascii file (csv, pts, xyz, …) using formulas to alter columns of data


Video Demonstration

The following video shows how to utilize the Modify ASCII File command


*** ## Command Interface Description

The Modify ASCII File command dialog looks as follows

Data file:
Select the ASCII File that you wish to modify. Selected file type options include *.PTS, *.TXT, *.CSV, or .. The file content should be row formatted data where the data items are separated by “,” (comma), “|” (pipe), “;” (semi colon), " " (space), or " " (Tab).

Preview:
The preview pane shows the first few rows of content for the data file selected

Column delimiter:
Select the data delimiter used in the file from the options provided - “,” (comma), “|” (pipe), “;” (semi colon), " " (space), or " " (Tab).

Skip first row checkbox:
If the first row of information is a header row, you can check this checkbox to eliminate it from the modification process.

Modifier Table:
The modifier table will be populated with the data values from the first row of data. For each column of information you will see the column number, the type of value e.g. Real, and the value read from the file of data. You can enter a formula into the formula area of the table to adjust the read value. For example if you want to multiply a value by -1 then enter *-1 in this field. The read value is assumed to be the first element of the formula. The result of the formulaic modification is displayed in the Result column as a check that you will get what you need on output.

Formula tips are provided in the dialog as an aid. Python programming language math functions are supported in the formula fields - for more information please contact us or refer to Python programming guides for more details. The following link may be helpful - Click Here

OK
Executes the command and closes on completion. The output file will be written into the same folder as the source file you selected on your computer. The file name will be the same as the source file name but with an extension .out.xxx where xxx is the original file extension i.e. if the original file was called Rockpile.PTS, the output file will be called Rockpile.out.PTS

Cancel
Closes the command without further execution.


Feedback and Enhancement Requests

If you would like to provide feedback on the use of the Modify ASCII File command or to request enhancements or improvements to the command please Click Here