Naming Conventions for Parameters and Variables
Applying Naming Conventions for Parameters and Variables
Arc uses configurable naming conventions to automatically prefix new variables and parameters when you create them in the TI editor. This ensures your team's code follows a consistent naming standard without manual effort.
How It Works
When you create a new variable or click Create Variable in Arc, Arc applies prefixes based on the rules defined in settings.yml. For example, with default settings, a numeric variable becomes vMyVariable and a string parameter becomes pMyParameter.
These prefixes are also used for variable-to-dimension matching in auto-complete — for example, a variable named vAccount will automatically be suggested in CELLGET/CELLPUT functions when a dimension named Account is in scope.
Default Naming Convention
The default naming convention is defined in settings.yml:
processnaming:
variablestring: v
variablenumeric: v
parameterstring: p
parameternumeric: p
constantstring: c
constantnumeric: c
numeric: "n"
string: sWith these defaults:
Variables:
vMyVariableParameters:
pMyParameterConstants:
cMyConstant
Customising the Naming Convention
To remove prefixes entirely or change them, update the relevant lines in settings.yml. For example, to remove the v prefix from variables:
processnaming:
variablestring:
variablenumeric:
parameterstring: p
parameternumeric: p
constantstring: c
constantnumeric: c
numeric: "n"
string: sAfter saving settings.yml, refresh the browser. The next time you click Create Variable, no prefix will be added.
Impact on Auto-Complete
Naming conventions also affect how Arc matches variables to dimensions in the auto-complete suggestions. If you change the naming convention, update your variable names accordingly to ensure auto-complete continues to work correctly.