is.monotone: Check monotonicity

Description Usage Arguments Value Examples

View source: R/is.monotone.R

Description

This internel function determines if a numeric vector X is monotone (increasing or decreasing) or not. Ties in the sequence are considered as monotone.

Usage

1

Arguments

X

a numerical vector to be tested.

Value

Returns True or False.

Examples

1
2
3
4
5
6
7
8
9
a <- 1:10 ;
b <- c( 1:5, 4:2 ) ;
c <- c( 1:4, 4, 4, 4, 5:10 ) ;
d <- c( 10:6, 3:-2 ) ;

is.monotone( a )
is.monotone( b )
is.monotone( c )
is.monotone( d )


tdROC documentation built on May 19, 2017, 9:04 p.m.
Search within the tdROC package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs in the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.