IntegerVariable.label

IntegerVariable.label(index)
Parameters:
  • i (int) – the index of the label we wish to return

  • index (int)

Returns:

the label at the given index

Return type:

str

Raises:

pyagrum.OutOfBounds – If the variable does not contain the label

Example

import pyagrum as gum

n = gum.IntegerVariable("n", "n", [1, 3, 10])
n.label(2)
# '10'

Class

IntegerVariable