Description Usage Arguments Details Value References Examples
Determining the ordering (montonicity) of a vector
1 2 3 | ordering(x, na.rm = TRUE)
monotonicity(x, na.rm = TRUE)
|
x |
numeric vector |
na.rm |
logical; whether to omit |
monotonicty
determines the monotonicy (first derivative) of a numeric
vector as one of:
stictly increasing,
increasing / montonically increasing / non-decreasing,
decreasing / monotonically decreasing / non-increasing,
strictly decreasing, or
constant
ordering tests, e.g. is_increasing are more efficient at testing.
monotonicity()
is an alias for ordering
.
integer;
2 : stictly increasing
1 : increasing / montonically increasing / non-decreasing
0 : non-ordered or constant
-1: decreasing / monotonically decreasing / non-increasing
-2: strictly decreasing
NA
:contains only
NAs all
na.rmdid not resolve all
NA's
http://en.wikipedia.org/wiki/Monotonic_function http://stackoverflow.com/questions/13093912/how-to-check-if-a-sequence-of-numbers-is-monotonically-increasing-or-decreasing
1 2 3 4 5 6 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.