cf.FieldList.where

FieldList.where(condition, x, y=None)[source]

Set data array elements depending on a condition.

fl.where(condition, x, y) is equivalent to for f in fl: f.where(condition, x, y).

See cf.Field.where for details.

Parameters:
condition :

Set the condition. See cf.Field.where for details.

x, y :

Specify the assignment values. See cf.Field.where for details.

Returns:

None

Previous topic

cf.FieldList.unsqueeze

Next topic

cf.FieldList.append

This Page