>=
Greater-than-or-equal operator: tests element by element whether A is at least B.
Category: Language Fundamentals > Operators and Elementary Operations
Syntax
C = A >= B
Applies the operator to A and B. Same as ge(A, B).
Description
Works like > but also accepts equality. The result is a logical array whose size follows implicit expansion. Comparisons with NaN are 0.
For complex operands only the real parts are compared.
Input arguments
A, B- Numeric, logical or char arrays (only the real part is compared for complex values). Sizes must be compatible, or one of them a scalar.
Output arguments
C- Logical array:
1where the relation holds,0elsewhere.
Example
scores = [55 70 62 90];
scores >= 60
mean(scores >= 60)
Output
ans = 1×4 logical array
0 1 1 1
ans = 0.7500