| Prev | Next | binbits |
| Syntax |
y = binbits(N) |
| Syntax |
y = binbits(N,M) |
| Include: |
include spt\binbits.oms |
| See Also | nrzbits |
ARGUMENTS:
INPUTS:
N = SCALAR, any numerical type, coerced to INTEGER
before processing. Represents the number of rows
in the returned matrix.
M = SCALAR, any numerical type, coerced to INTEGER
before processing. Represents the number of
columns in the returned matrix.
RETURN: MATRIX, type INTEGER, equi-probable binary bits.
Create matrix of random bits (0 or 1).
Returns a matrix filled with equi-probable binary bits,
i.e., 1s and 0s. Integer type in returned.
O>binbits(5,6)
{
[ 0 , 1 , 0 , 1 , 0 , 1 ]
[ 0 , 1 , 1 , 1 , 0 , 1 ]
[ 0 , 0 , 0 , 1 , 0 , 0 ]
[ 1 , 0 , 0 , 1 , 0 , 0 ]
[ 1 , 1 , 1 , 0 , 1 , 0 ]
}