setFilterWidget {AnalysisPageServer} | R Documentation

## `setFilterWidget` sets the filter widget for the current analysis. This is the function most commonly used.

### Description

`setFilterWidget` sets the filter widget for the current analysis. This is the function most commonly used.

`getFilterWidget` retrieve the filter widget for the current analysis. This is normally used internally, to construct the final response for the analysis.

The AnalysisPageFilterWidget object specifies a "filter widget" to be displayed to the user. This is a grid of colored squares, each of which controls the filtering of a subset of the samples based on the values of a pheno field. This object specifies the dimension of the grid, the colors of the squares, rollovers to appear for each square, and the subset of samples that each square filters.

### Usage

    setFilterWidget(data.field, color, cells, inactive.color = "gray",
      type = "filter_grid")

    getFilterWidget()

    new.filter.widget(data.field, color, cells, inactive.color = "gray",
      type = "filter_grid")

### Arguments

`data.field` | Name of table field which should be used for filtering.
`color` | Named character vector. Names should be values (or possible values) that the data field could take on. Values are string specifying colors. These are passed through directly to javascript so they should be valid colors there, whatever that means.
`cells` | Character matrix. This gives the layout of the filter grid. The values should all be either taken from `names(color)` or else be NA values. The NA values will be inactive (no rollover or click listeners).
`inactive.color` | Color for inactive cells (that are the positions with `is.na(cells)`). Default: "gray"
`type` | Filter widget type. The only currently supported type is "filter_grid".

### Details

`new.filter.widget` is the constructor for this object. This should be used when constructing an `AnalysisPageReponse` explicitly, with the return value then passed to `new.datanode.plot`.

### Value

`setFilterWidget` returns the newly set AnalysisPageFilterWidget object

`getFilterWidget` returns the curretn AnalysisPageFilterWidget object, or NULL if it has not yet been set

`new.filter.widget` returns an `AnalysisPageFilterWidget`

### Author(s)

Brad Friedman

[Package AnalysisPageServer version 1.18.1 Index]