rank: Methods for Function 'rank' in Package 'scidb'

Description Usage Arguments Value Note Author(s) Examples

Description

rank Returns the sample ranks of the values in a vector. Ties (i.e., equal values) and missing values can be handled in several ways.

Usage

1
2
3
## S4 method for signature 'scidb'
rank(x, na.last = TRUE,
          ties.method = c("average", "first", "random", "max", "min"))

Arguments

x

A scidb vector object.

na.last

NOT USED–for compatability with native R functions only.

ties.method

SciDB supports average or random.

Value

A scidb reference object.

Note

Select either average or random for ties.method. If all components are different (and no 'NA's), the ranks are well defined, with values in 'seq_len(x)'. With some values equal (called 'ties'), the argument 'ties.method' determines the result at the corresponding indices. The random method puts these in random order whereas the default, average, replaces them by their mean.

Author(s)

B. W. Lewis <blewis@paradigm4.com>

Examples

1
2
3
4
5
6
7
## Not run: 
x <- scidb("build(<v:double>[i=1:10,10,0],random()

a <- order.scidb(x)
print(a)

## End(Not run)


Search within the scidb package
Search all R packages, documentation and source code

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

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

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