SETVARS

\label{sec:setvars}

The SETVARS command sets the variables with values extracted from the row of a table.

\madbox

SETVARS, TABLE=tabname, ROW=integer;

The attributes of SETVARS are:

{madlist}\ttitem

TABLE the name of the table. (Default: none) \ttitemROW the row number containing the values. (Default: -1)

Negative ROW values are allowed and count the row numbers from the last row, allowing access to the table in reverse order of rows: ROW = -1 accesses the last row of the table, ROW = -2 accesses the penultimate (one before last) row, etc…

Trying to access the table forward beyond the last row, i.e. ROW strictly greater than nrow the number of rows in the table, or trying to access the table backwards before the first row, i.e. ROW strictly lower than -nrow, or trying to access the illegal ROW=0, all result in a “row out of bound” message and no variable values are returned and set.