coerce-method {maigesPack} | R Documentation

## Coerce a maiges object to classes defined by packages limma and marray

### Description

Coercing methods were defined to convert maiges objects of classes `maiges` and `maigesRaw` into objects of classes `marrayNorm` and `marrayRaw` from package marray or classes `MAList` and `RGList` from package limma and vice-versa.

### Usage

    ## S4 method for signature 'maiges, marrayNorm':
    as(from, to)

    ## S4 method for signature 'marrayNorm, maiges':
    as(from, to)

    ## S4 method for signature 'maiges, MAList':
    as(from, to)

    ## S4 method for signature 'MAList, maiges':
    as(from, to)

    ## S4 method for signature 'maigesRaw, marrayRaw':
    as(from, to)

    ## S4 method for signature 'marrayRaw, maigesRaw':
    as(from, to)

    ## S4 method for signature 'maigesRaw, RGList':
    as(from, to)

    ## S4 method for signature 'RGList, maigesRaw':
    as(from, to)

### Arguments

`from` | object of class `maiges`, `maigesRaw`, `MAList`, `RGList`, `marrayNorm` or `marrayRaw`.
`to` | character string specifying the class of object to which the object `from` will be coerced

### Details

When converting from objects of classes `RGList` or `marrayRaw` to class `maigesRaw`, the slot `Sf` and `Sb` will always receive the channel 2 (red) values, and `Rf` and `Rb` will always receive channel 1 (green) values. For the normalized ojects, the slot `W` will be equivalent to the M values.

When converting from objects of classes `maigesRaw` or `maiges` to classes `RGList`, `marrayRaw`, `MAList` or `marrayNorm` the correct values of the two channels or of M values are calculated.

### Methods

from = maiges, to = marrayNorm
  convert an object of class `maiges` into an object of class `marrayNorm`.
from = marrayNorm, to = maiges
  convert an object of class `marrayNorm` into an object of class `maiges`.
from = maiges, to = MAList
  convert an object of class `maiges` into an object of class `MAList`.
from = MAList, to = maiges
  convert an object of class `MAList` into an object of class `maiges`.
from = maigesRaw, to = marrayRaw
  convert an object of class `maigesRaw` into an object of class `marrayRaw`.
from = marrayRaw, to = maigesRaw
  convert an object of class `marrayRaw` into an object of class `maigesRaw`.
from = maigesRaw, to = RGList
  convert an object of class `maigesRaw` into an object of class `RGList`.
from = RGList, to = maigesRaw
  convert an object of class `RGList` into an object of class `maigesRaw`.

### Note

It is possible to use Package convert to convert objects between classes defined in packages limma, marray and Biobase.

### See Also

`as` in the methods package.

### Examples

    ## Loading the dataset
    data(gastro)

    ## Converting a maigesRaw class object into marrayRaw object
    as(gastro.raw, "marrayRaw")

    ## Converting a maigesRaw class object into RGList
    as(gastro.raw, "RGList")

    ## Converting a maiges class object into marrayNorm object
    as(gastro.norm, "marrayNorm")

    ## Converting a maiges class object into MAList object
    as(gastro.summ, "MAList")

[Package maigesPack version 1.2.1 Index]