allEqual: Test whether all elements of a vector are equal
Description
This function tests whether all elements of the specified vector are equal
to each other, i.e., whether the vector contains only a single unique value.
For lists, equality is determined using equivalent.
Usage
allEqual(x, ignoreMissing = FALSE, ...)
Value
TRUE if all elements test equivalent; FALSE
otherwise.
Arguments
x
A vector of any mode, including a list.
ignoreMissing
If TRUE, missing elements will be ignored.
Otherwise the presence of missing values will result in a return value of
FALSE.
...
Additional arguments to all.equal, via
equivalent.
Author
Jon Clayden
References
Please cite the following reference when using TractoR in your
work:
J.D. Clayden, S. Muñoz Maniega, A.J. Storkey, M.D. King, M.E. Bastin & C.A.
Clark (2011). TractoR: Magnetic resonance imaging and tractography with R.
Journal of Statistical Software 44(8):1-18. tools:::Rd_expr_doi("10.18637/jss.v044.i08").
See Also
equivalent for elementwise equivalence of two
vectors.