Skip to content

index_values

Syntax

index_values(list-expression, operator, expression)

Parameters

list-expression
list the function is applied to.
operator
mathematical comparison operator: <, <=, >, >=, ==, or !=.
expression
expression that <op> is applied to in relation to <list_expr>.

Returns

Sub-list of the index values that satisfy the given test.

Description

List action that returns the list of the index values that satisfy the given test.

Use of the prefix form, such as gt rather than infix form >, for <op> results in an error.

Examples

The following results in index_list equal to list(1,2,4):

old_list = list(2,10,8,4,6)
index_list = index_values(old_list, >, old_list[0] + 3)

See Also