This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
howtos:importing_informant_definitions_-_sets_and_categories [2012/09/05 19:19] marcus.williams |
howtos:importing_informant_definitions_-_sets_and_categories [2016/03/01 14:35] marcus.williams [Element names - characters to avoid] |
||
---|---|---|---|
Line 170: | Line 170: | ||
It is highly reccomended that whitespace and other non-alphanumeric characters be avoided in element names. | It is highly reccomended that whitespace and other non-alphanumeric characters be avoided in element names. | ||
- | [Describe the searchElemName and replaceElemName parameters in the create tool. Provide examples.] FIXME | + | Here is an example: |
+ | |||
+ | <code> | ||
+ | localinformant employmentSector_d[] = create (; object=set, delimiter=",", \ | ||
+ | allowDuplicate=off, \ | ||
+ | elemNamesFromColNum=1, firstLine=1, \ | ||
+ | searchElemName1=",", replaceElemName1="", \ | ||
+ | searchElemName2=".", replaceElemName2="_", \ | ||
+ | searchElemName3="&", replaceElemName3="and", \ | ||
+ | searchElemName4="/", replaceElemName4="_", \ | ||
+ | searchElemName5="(", replaceElemName5="", \ | ||
+ | searchElemName6=")", replaceElemName6="", \ | ||
+ | searchElemName7="]", replaceElemName7="", \ | ||
+ | searchElemName8="[", replaceElemName8="", \ | ||
+ | searchElemName9="-", replaceElemName9="_", \ | ||
+ | searchElemName10="'", replaceElemName10="", \ | ||
+ | searchElemName11="$", replaceElemName11="dlr", \ | ||
+ | searchElemName12="%", replaceElemName12="pct", \ | ||
+ | searchElemName13=":", replaceElemName13="", \ | ||
+ | stripLeadingWhiteSpace=off, \ | ||
+ | replaceWhiteSpaceInElemName="_" , \ | ||
+ | file=$fileName) | ||
+ | </code> | ||
====== Creating a Category Object ====== | ====== Creating a Category Object ====== | ||
Line 176: | Line 198: | ||
===== Specifying the Category Definition from Parameters ===== | ===== Specifying the Category Definition from Parameters ===== | ||
- | Stuff here | + | Example: |
+ | <code> | ||
+ | localinformant egtCOfte_nr[] = create (; object=category, \ | ||
+ | desc="elecGenTech category of fuelTypeElec", \ | ||
+ | groups = elecGenTech, \ | ||
+ | members = fuelTypeElec, \ | ||
+ | delimiter = ",", \ | ||
+ | "combSteamSF" = "coal,heavyOil,petroleumCoke,naturalGas", \ | ||
+ | "combTurbineSF" = "coal,heavyOil,petroleumCoke,naturalGas", \ | ||
+ | "combineCycleSF" = "coal,heavyOil,petroleumCoke,naturalGas", \ | ||
+ | "nucLWSteam" = "urainium", \ | ||
+ | "nucHWSteam" = "urainium", \ | ||
+ | "combSteamMF" = "multiFuel", \ | ||
+ | "combTurbineMF" = "multiFuel", \ | ||
+ | "combineCycleMF" = "multiFuel", \ | ||
+ | "industrialSector" = "nonSpecifiedFuel", \ | ||
+ | "commercialSector" = "nonSpecifiedFuel") | ||
+ | </code> |