minmax | R Documentation |
Returns TRUE
if and only if all elements of a vector are identical.
minmax(x, tol=1e-6)
x |
Vector to be tested |
tol |
Relative tolerance allowed |
If x
is an integer, exact equality is required. If real or
complex, a relative tolerance of tol
is required. Note that
functions such as is.magic()
and is.semimagichypercube()
use the default value for tol
. To change this,
define a new Boolean function that tests the sum to the required
tolerance, and set boolean
to TRUE
Robin K. S. Hankin
is.magic()
data(Ollerenshaw) minmax(subsums(Ollerenshaw,2)) #should be TRUE, as per is.2x2.correct()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.