asserts.greaterThan
Check that every value is strictly greater than a limit.
📝Syntax
asserts.greaterThan(value, limit)
[res, msg] = asserts.greaterThan(value, limit)
📥Input Arguments
Parameter Description
value Real numeric or logical scalar or array.
limit Real numeric or logical scalar or array. Scalar expansion is supported.
📤Output Arguments
Parameter Description
res true if the assertion passes, false otherwise.
msg assertion failure message, empty on success.
📄Description

The assertion passes when value > limit for every compared element.

Arrays must have the same dimensions unless one input is scalar.

💡Examples
Scalar expansion
asserts.greaterThan([2 3], 1);
Capture a relation failure
[res, msg] = asserts.greaterThan([0 3], 1);
🔗See Also
asserts.greaterOrEqualasserts.inRange
🕔Version History
Version Description
2.0.0 initial version
Edit this page on GitHub