replaceWithOtherFieldIf method
- required BooleanFieldFunction selection,
- required ContinuousFieldFunction otherField,
Composes a function that preserves values from this function's field result or replaces them with values from another.
Values are replaced point-wise across the spatial intersection of the selection with the union of the two function's field results. Where the selection is true, values from the other field are returned. Where the selection is false, values from this function's field result are returned. The function result has no data where the selection or the selected field has no data.
The function result extent is the intersection of the selection with the union of this function's field result and the other.
The spatial reference of this function's field result, the other, and the selection must be equivalent.
Parameters:
selection— A selection.otherField— The continuous field function to draw values from when replacing.
Return Value: A function that preserves values from this function's field result or replaces them with values from another.