Last data update: 2014.03.03

R: Class "CdfEnvAffy"
CdfEnvAffy-classR Documentation

Class "CdfEnvAffy"

Description

A class to hold the information necessary to handle the grouping of probes in set of probes, and to find XY coordinates of probes on a chip

Objects from the Class

Objects can be created by calls of the form new("CdfEnvAffy", ...). Typically, there is an instance of the class for each type of chip (e.g. Hu6800, HG-U95A, etc...).

Slots

envir:

Object of class "environment". It has to be thought of as a hashtable: the keys are probe set identifiers, or gene names, and the values are indexes.

envName:

Object of class "character". A name for the environment.

index2xy:

Object of class "function". The function used to resolve index into xy coordinates. Unless you are an advanced user, you probably want to ignore this (and rely on the default provided with the package).

xy2index:

Object of class "function". The function used to resolve xy coordinates into index. Unless you are an advanced user, you probably want to ignore this (and rely on the default provided with the package).

nrow:

Object of class "integer". The number of rows of probes for the chip type.

ncol:

Object of class "integer". The number of columns of probes for the chip type.

probeTypes:

Object of class "character". The different types of probes stored for each probe set. In the case of Affymetrix chips, the probes are typically perfect match (pm) probes or mismatch probes (mm).

chipType:

Object of class "character". The name of the chip type the instance is associated with. This is useful when one starts to create alternative mappings of the probes on a chip (see associated vignette).

Methods

[

signature(object = "CdfEnvAffy", i = "character", j = "missing", drop = "boolean"): subset a cdf, that is return a new cdf containing only a subset of the probe sets. The subset of probe sets to take is identified as a vector of identifiers (mode "character").

coerce

signature(object = "CdfEnvAffy", "environment"): coerce an instance of the class to an environment.

coerce

signature(object = "CdfEnvAffy", "Cdf"): coerce an instance of the class to a Cdf.

geneNames

signature(object="CdfEnvAffy"): Return the names of the known probe sets (of course, it depends on the associated CDF).

index2xy

signature(object = "CdfEnvAffy", i="integer"): convert index values into XY coordinates.

indexProbes

signature(object = "CdfEnvAffy", which = "character", probeSetNames = NULL): obtain the indexes for the probes associated wit the probe set name probeSetNames. When probeSetNames is set to NULL (default), the indexes are returned for the probe sets defined on the chip. See indexProbes.CdfEnvAffy

plot

signature(x = "CdfEnvAffy", y = "missing"): Plot the chip. It mainly sets coordinates for further plotting (see examples). See plot.CdfEnvAffy

show

signature(object = "CdfEnvAffy"): Print method.

xy2index

signature(object = "CdfEnvAffy", x="integer", y="integer"): convert XY coordinates into index values.

toHypergraph

signature(object = "CdfEnvAffy"): convert XY coordinates into index values.

Author(s)

Laurent Gautier

See Also

indexProbes.CdfEnvAffy, plot.CdfEnvAffy

Examples

## build an instance
library(hgu95acdf)
cdfenv.hgu95a <- wrapCdfEnvAffy(hgu95acdf, 640, 640, "HG-U95A")

show(cdfenv.hgu95a)

## find the indexes for a probe set (pm only)
ip <- indexProbes(cdfenv.hgu95a, "pm", "1000_at")[[1]]
## get the XY coordinates for the probe set
xy <- index2xy(cdfenv.hgu95a, ip)

## plot the chip
plot(cdfenv.hgu95a)

## plot the coordinates
plotLocation(xy)

## subset the environment

cdfenv.hgu95a.mini <- cdfenv.hgu95a["1000_at"]

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(altcdfenvs)
Loading required package: BiocGenerics
Loading required package: parallel

Attaching package: 'BiocGenerics'

The following objects are masked from 'package:parallel':

    clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
    clusterExport, clusterMap, parApply, parCapply, parLapply,
    parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked from 'package:stats':

    IQR, mad, xtabs

The following objects are masked from 'package:base':

    Filter, Find, Map, Position, Reduce, anyDuplicated, append,
    as.data.frame, cbind, colnames, do.call, duplicated, eval, evalq,
    get, grep, grepl, intersect, is.unsorted, lapply, lengths, mapply,
    match, mget, order, paste, pmax, pmax.int, pmin, pmin.int, rank,
    rbind, rownames, sapply, setdiff, sort, table, tapply, union,
    unique, unsplit

Loading required package: S4Vectors
Loading required package: stats4

Attaching package: 'S4Vectors'

The following objects are masked from 'package:base':

    colMeans, colSums, expand.grid, rowMeans, rowSums

Loading required package: Biobase
Welcome to Bioconductor

    Vignettes contain introductory material; view with
    'browseVignettes()'. To cite Bioconductor, see
    'citation("Biobase")', and for packages 'citation("pkgname")'.

Loading required package: affy
Loading required package: makecdfenv
Loading required package: affyio
Loading required package: Biostrings
Loading required package: IRanges
Loading required package: XVector
Loading required package: hypergraph
Loading required package: graph

Attaching package: 'graph'

The following object is masked from 'package:Biostrings':

    complement

> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/altcdfenvs/CdfEnvAffy-class.Rd_%03d_medium.png", width=480, height=480)
> ### Name: CdfEnvAffy-class
> ### Title: Class "CdfEnvAffy"
> ### Aliases: CdfEnvAffy-class geneNames,CdfEnvAffy-method
> ###   index2xy,CdfEnvAffy-method indexProbes,CdfEnvAffy,character-method
> ###   plot,CdfEnvAffy,missing-method show,CdfEnvAffy-method
> ###   xy2index,CdfEnvAffy-method coerce,CdfEnvAffy,environment-method
> ###   coerce,CdfEnvAffy,Cdf-method toHypergraph,CdfEnvAffy-method
> ###   [,CdfEnvAffy,character,missing,missing-method
> ### Keywords: classes
> 
> ### ** Examples
> 
> ## build an instance
> library(hgu95acdf)

Warning messages:
1: replacing previous import 'AnnotationDbi::tail' by 'utils::tail' when loading 'hgu95acdf' 
2: replacing previous import 'AnnotationDbi::head' by 'utils::head' when loading 'hgu95acdf' 
> cdfenv.hgu95a <- wrapCdfEnvAffy(hgu95acdf, 640, 640, "HG-U95A")
> 
> show(cdfenv.hgu95a)
Instance of class CdfEnvAffy:
 name     : HG-U95A 
 chip-type: HG-U95A 
 size     : 640 x 640 
 12626 probe set(s) defined.
> 
> ## find the indexes for a probe set (pm only)
> ip <- indexProbes(cdfenv.hgu95a, "pm", "1000_at")[[1]]
> ## get the XY coordinates for the probe set
> xy <- index2xy(cdfenv.hgu95a, ip)
> 
> ## plot the chip
> plot(cdfenv.hgu95a)
> 
> ## plot the coordinates
> plotLocation(xy)
> 
> ## subset the environment
> 
> cdfenv.hgu95a.mini <- cdfenv.hgu95a["1000_at"]
> 
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>