whereAre {eatTools}R Documentation

Matches a scalar with elements of a vector.

Description

The function closely resembles the match function, but allows for multiple matches.

Usage

whereAre(a,b,verbose=TRUE)

Arguments

a

a scalar

b

a numeric or character vector

verbose

logical: print messages on console?

Value

A numeric vector

Author(s)

Sebastian Weirich

Examples

a <- 12
b <- c(10, 11, 12, 10, 11, 12)
match(a, b)
whereAre(a=a, b=b)

[Package eatTools version 0.6.0 Index]