readCdfDataFrame {affxparser} | R Documentation

## Reads units (probesets) from an Affymetrix CDF file

### Description

Reads units (probesets) from an Affymetrix CDF file. Gets all or a subset of units (probesets).

### Usage

    readCdfDataFrame(filename, units=NULL, groups=NULL, cells=NULL, fields=NULL, drop=TRUE,
      verbose=0)

### Arguments

`filename` | The filename of the CDF file.
`units` | An `integer` `vector` of unit indices specifying which units to be read. If `NULL`, all are read.
`groups` | An `integer` `vector` of group indices specifying which groups to be read. If `NULL`, all are read.
`cells` | An `integer` `vector` of cell indices specifying which cells to be read. If `NULL`, all are read.
`fields` | A `character` `vector` specifying what fields to read. If `NULL`, all unit, group and cell fields are returned.
`drop` | If `TRUE` and only one field is read, then a `vector` (rather than a single-column `data.frame`) is returned.
`verbose` | An `integer` specifying the verbose level. If 0, the file is parsed quietly. The higher numbers, the more details.

### Value

An NxK `data.frame` or a `vector` of length N.

### Author(s)

Henrik Bengtsson

### References

[1] Affymetrix Inc, Affymetrix GCOS 1.x compatible file formats, June 14, 2005. http://www.affymetrix.com/support/developer/

### See Also

For retrieving the CDF as a `list` structure, see `readCdfUnits`.

### Examples

    ##############################################################
    if (require("AffymetrixDataTestFiles")) {            # START #
    ##############################################################

    # Find any CDF file
    cdfFile <- findCdf()

    units <- 101:120
    fields <- c("unit", "unitName", "group", "groupName", "cell")
    df <- readCdfDataFrame(cdfFile, units=units, fields=fields)
    stopifnot(identical(sort(unique(df$unit)), units))

    fields <- c("unit", "unitName", "unitType")
    fields <- c(fields, "group", "groupName")
    fields <- c(fields, "x", "y", "cell", "pbase", "tbase")
    df <- readCdfDataFrame(cdfFile, units=units, fields=fields)
    stopifnot(identical(sort(unique(df$unit)), units))

    ##############################################################
    }                                                     # STOP #
    ##############################################################

[Package affxparser version 1.66.0 Index]