User Tools

Site Tools


howtos:workwithdata:createreaddatafiles

Use create pick apart complicated data files

It's always best to not touch a data file when trying to import it. Create has many feature to help with that and most situations should be covered by these parameters.

Here's a tar file with several examples and data.

  • Download and un-zip it somewhere on your server where you have access to it with interactive tool, on any account.
  • The best way to learn about the features is to work through the test.t script file in the above tar file looking at the results as you go.

Important Parameters

ignoreExtraCols=on/off - Always run without this first and check out any errors or warnings about your input data however if you determine there are just extra empty columns

ignoreMissingCols=on/off - or missing columns that you don't mind padding with 0's then turn on this parameter.

delimiter - works for both coordinate and odometer format now

searchElemName1 and replaceElemName1 - use this to search and replace pair to match up with the changes to element names you may have made when extracting the informant for this data. Must be used together

replaceWhiteSpaceInElemName - replace any tab, space or other “white space” in the element names and should also be used to match up with the element name changes you may have made when extracting the informant set

firstLine - this is the line the data starts on and is counted from the top of the file even if there are lines commented out with '!'

firstCol - this is the first column to consider and is a 1 based value so the first column is 1

  • In coordinate format that means the first column that has coordinate element names in it.
  • In odometer format that means the first column that has data in it, if this is used the rowTitles parameter is ignored

Indexing

When you have a non-numeric column and have an informant for these values you can take in the data as the indexed numeric value. Then later when writing it out you can index it back to this informant and write out the text.

howtos/workwithdata/createreaddatafiles.txt · Last modified: 2011/05/13 12:30 by shona.weldon