Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

vlapply

Apply a function with a predefined return value


Description

These are just wrappers around vapply with argument FUN.VALUE set. The function is expected to return a single logical, integer, numeric or character value, depending on the second letter of the function name.

Usage

vlapply(x, fun, ..., use.names = TRUE)

viapply(x, fun, ..., use.names = TRUE)

vnapply(x, fun, ..., use.names = TRUE)

vcapply(x, fun, ..., use.names = TRUE)

Arguments

x

[vector or list]
Object to apply function on.

fun

[function]
Function to apply on each element of x.

...

[ANY]
Additional arguments for fun.

use.names

[logical(1)]
Should result be named? Default is TRUE.


BBmisc

Miscellaneous Helper Functions for B. Bischl

v1.11
BSD_2_clause + file LICENSE
Authors
Bernd Bischl [aut, cre], Michel Lang [aut], Jakob Bossek [aut], Daniel Horn [aut], Jakob Richter [aut], Dirk Surmann [aut]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.