change~ Reference

Report signal direction

change~

Description

Use the change object to monitor increase, decrease, or no change in a signal value.

Examples

Detect whether a signal is increasing, decreasing, or remaining constant

Arguments

None.

Attributes

Common Box Attributes

Messages

float

Arguments

input [float]
You can set the value stored with a float.

signal

Any signal to be watched for changed and unchanged values.

Output

signal

When the current sample is greater in value than the previous sample, change~ outputs a sample of 1. When the current sample is the same as the previous sample, change~ outputs a sample of 0. When the current sample is less than the previous sample, change~ outputs a sample of -1.

See Also

Name Description
edge~
thresh~
zerox~