Skip to content

SUBTRACT

The SUBTRACT function subtracts the score of a domain in a specified set by a value.
The SUBTRACT function changes the value of Score in the hidden results table.

For example, if a set variable workingSet has these contents from the sample taxonomy in the introduction:

1.01    martial art
    1.01.1  aikido
1.07    golf

and the hidden results table is the one in the introduction, then this statement:

SUBTRACT(workingSet, "1.01", 10);

will subtract ten points from the score of domain 1.01 (60) that will become 50.

Since the only domains with a score are those listed in the hidden results table, only domains with a matching entry in that table are affected.

The syntax is:

SUBTRACT(set, domain, number)

where:

  • set is a set variable.
  • domain is a domain name or ID.
  • number is the number to subtract. It can be an integer or a decimal number.