SRFilter-class {ShortRead} | R Documentation

## "SRFilter" for representing functions operating on ShortRead objects

### Description

Objects of this class are functions that, when provided an appropriate object from the ShortRead package, return logical vectors indicating which parts of the object satisfy the filter criterion.

A number of filters are built-in (described below); users are free to create their own filters, using the `srFilter` function.

### Objects from the Class

Objects can be created through `srFilter` (to create a user-defined filter) or through calls to constructors for predefined filters, as described on the `srFilter` page.

### Slots

`.Data`:

  Object of class `"function"` taking a single named argument `x` corresponding to the ShortRead object that the filter will be applied to. The return value of the filter function is expected to be a logical vector that can be used to subset `x` to include those elements of `x` satisfying the filter.

`name`:

  Object of class `"ScalarCharacter"` representing the name of the filter. The name is useful for suggesting the purpose of the filter, and for debugging failed filters.

### Extends

Class `"function"`, from data part. Class `".SRUtil"`, directly. Class `"OptionalFunction"`, by class "function", distance 2. Class `"PossibleMethod"`, by class "function", distance 2.

### Methods

srFilter

  `signature(fun = "SRFilter")`: Return the function representing the underlying filter; this is primarily for interactive use to understanding filter function; usually the filter is invoked as a normal function call, as illustrated below

name

  `signature(x = "SRFilter")`: Return, as a `ScalarCharacter`, the name of the function.

show

  `signature(object = "SRFilter")`: display a brief summary of the filter

coerce

  `signature(from = "SRFilter", to = "FilterRules")`: Coerce a filter to a `FilterRules` object of length one.

c

  `signature(x = "SRFilter", ...)`: Combine filters into a single `FilterRules` object.

### Author(s)

Martin Morgan <mtmorgan@fhcrc.org>

### See Also

`srFilter` for predefined and user-defined filters.

### Examples

    ## see ?srFilter

[Package ShortRead version 1.42.0 Index]