R: Creates a first FALSE exiting function from the list of...
filterfun
R Documentation
Creates a first FALSE exiting function from the list of
filter functions it is given.
Description
This function creates a function that takes a single argument. The
filtering functions are bound in the environment of the returned
function and are applied sequentially to the argument of the returned
function. When the first filter function evaluates to FALSE the
function returns FALSE otherwise it returns TRUE.
Usage
filterfun(...)
Arguments
...
Filtering functions.
Value
filterfun returns a function that takes a single argument. It
binds the filter functions given to it in the environment of the
returned function. These functions are applied sequentially (in the
order they were given to filterfun). The function returns
FALSE (and exits) when the first filter function returns
FALSE otherwise it returns TRUE.
Author(s)
R. Gentleman
See Also
genefilter
Examples
set.seed(333)
x <- matrix(rnorm(100,2,1),nc=10)
cvfun <- cv(.5,2.5)
ffun <- filterfun(cvfun)
which <- genefilter(x, ffun)
Results
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(genefilter)
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/genefilter/filterfun.Rd_%03d_medium.png", width=480, height=480)
> ### Name: filterfun
> ### Title: Creates a first FALSE exiting function from the list of filter
> ### functions it is given.
> ### Aliases: filterfun
> ### Keywords: manip
>
> ### ** Examples
>
> set.seed(333)
> x <- matrix(rnorm(100,2,1),nc=10)
> cvfun <- cv(.5,2.5)
> ffun <- filterfun(cvfun)
> which <- genefilter(x, ffun)
>
>
>
>
>
> dev.off()
null device
1
>