Name

ValueWhen — Get a value of the array when condition met

Synopsis

ValueWhen (EXPRESSION,
  ARRAY,
  n = 1);

Returns

ARRAY

Parameters

Name Type Default Description
EXPRESSION boolean
ARRAY array
n number 1

Description

This function is inspired by AmiBroker function: www.amibroker.com/guide/afl/valuewhen.html

Get a value of the array when condition met