ExposomeSet {rexposome} | R Documentation

## Class ExposomeSet

### Description

Class `ExposomeSet` contains the exposure levels, the exposure's description and the samples phenotype. It is the starting object for `rexposome` package and extends eSet.

### Usage

    ## S4 method for signature 'ExposomeSet,ANY'
    plot(x, y, ...)

    ## S4 method for signature 'ExposomeSet'
    clustering(object, method, cmethod, ...,
      warnings = TRUE)

    ## S4 method for signature 'ExposomeSet'
    correlation(object, ..., warnings = TRUE)

    ## S4 method for signature 'ExposomeSet'
    dim(x)

    ## S4 method for signature 'ExposomeSet'
    expos(object)

    ## S4 method for signature 'ExposomeSet'
    exposureNames(object)

    ## S4 method for signature 'ExposomeSet'
    exwas(object, formula, filter, family, ..., baselevels,
      tef = TRUE, verbose = FALSE, warnings = TRUE)

    ## S4 method for signature 'ExposomeSet'
    familyNames(object, by.exposure = FALSE)

    ## S4 method for signature 'ExposomeSet'
    highAndLow(object, ngroups = 3,
      intervals = c("standard", "extreme"), select, drop = FALSE,
      warnings = TRUE)

    ## S4 method for signature 'ExposomeSet'
    ilod(object, seed = 1234, lod.col = "LOD",
      pNA = 0.2, tLog = FALSE, method = "QRILC", warnings = TRUE, ...)

    ## S4 method for signature 'ExposomeSet'
    imputation(object, select, ..., messages = FALSE)

    ## S4 method for signature 'ExposomeSet'
    mexwas(object, phenotype, family, warnings = TRUE)

    ## S4 method for signature 'ExposomeSet'
    normalityTest(object, exposure, th = 0.05,
      min.val = 5, na.rm = TRUE, warnings = TRUE)

    ## S4 method for signature 'ExposomeSet'
    pca(object, npc = 10)

    ## S4 method for signature 'ExposomeSet'
    phenotypeNames(object)

    ## S4 method for signature 'ExposomeSet'
    plotFamily(x, family, group, group2, scatter = TRUE,
      na.omit = TRUE)

    ## S4 method for signature 'ExposomeSet'
    plotHistogram(x, select, density = TRUE,
      show.trans = FALSE)

    ## S4 method for signature 'ExposomeSet'
    plotLOD(object, lod.col = "LOD", x.max = 100,
      sort = TRUE)

    ## S4 method for signature 'ExposomeSet'
    plotMissings(object, set = c("exposures",
      "phenotypes"), x.max = 100, sort = TRUE)

    ## S4 method for signature 'ExposomeSet'
    standardize(object, select, method = "normal",
      na.rm = TRUE, warnings = TRUE)

    ## S4 method for signature 'ExposomeSet'
    Summary(x, set = c("exposures", "phenotypes"), select,
      ..., na.rm = FALSE)

    ## S4 method for signature 'ExposomeSet'
    tableLOD(object, output = "n", lod.col = "LOD",
      sort = TRUE)

    ## S4 method for signature 'ExposomeSet'
    tableMissings(object, set = c("exposures",
      "phenotypes"), output = "n", sort = TRUE)

    ## S4 method for signature 'ExposomeSet'
    trans(object, fun, select, by.exposure = FALSE, ...)

### Arguments

`x` | An `ExposomeSet` object.
`y` | NOT USED
`...` | Argument sent given method.
`object` | An `ExposomeSet` object.
`method` | Method to be used.
`cmethod` | Function implementing a systsme to retrieve classification from clustering output
`warnings` | If set to `TRUE` shows intermediate warnings.
`formula` | Formula, not including exposures, to be tested.
`filter` | Expression to be used to filter `ExposomeSet`
`family` | Family descriving the nature of the health outcome
`baselevels` | Labeled vector with the default base level for categorical exposures.
`tef` | If `TRUE` it computed the threshold for effective tests.
`verbose` | If set to `TRUE` is shows messages on progression.
`by.exposure` | If set to `TRUE` ir returns the family which each exposure belongs
`ngroups` | Number of intervals to be used
`intervals` | If `"standard"` all levels are kept, if `"extreme"` intermetiate levels are set to `NA`.
`select` | Vector selecting thee xposures to be used.
`drop` | If set to `TRUE` exposures are replaced
`seed` | Numeric seed
`lod.col` | Indicator of the column where the LOD is located
`pNA` | Maximum percentage allowed of values under LOD
`tLog` | If set to `TRUE` it transforms all the exposures to lod before the imputation.
`messages` | If set to `TRUE` messages from `mice`'s function will be displayed.
`phenotype` | Health outcome to be used as dependent variable.
`exposure` | Vecror of exposures to be used.
`th` | Threshold of P-Value used to considere normalit
`min.val` | Minimum number of observations to perform test
`na.rm` | If set to `TRUE` removes `NA` values
`npc` | Number of PC to be kept
`group` | Phenotype to group exposures
`group2` | Phenotype to group exposures
`scatter` | If set to true it shows the samples value in the plot
`na.omit` | If set to `TRUE`, `NA` values are discarded
`density` | If set to `TRUE` a desntiry plot is draw on the histogram
`show.trans` | If set to `TRUE`, three extra plots are drawn with usual transformations
`x.max` | Threshold for x axis (in %)
`sort` | If set to `TRUE`, results are ordered
`set` | Cantake values `"exposures"` or `"phentoypes"`.
`output` | Can take values `"n"` (count) ot `"p"` (percentage)
`fun` | Function to bt used in the transformation process

### Value

An object of class `ExposomeSet`

### Methods (by generic)

- `plot`: Wrapper for `plotFamily` method.

- `clustering`: Performs clustering on samples based on exposure levels.

- `correlation`: Computes correlation on exposures.

- `dim`: Returns the number of exsures, samples and phenotypes.

- `expos`: Returns a `data.frame` with exposures.

- `exposureNames`: Getter to obtain the exposures's names.

- `exwas`: Performs an EXposome-Wide Association Study

- `familyNames`: Getter to obtain the families's names of the family of each exposure.

- `highAndLow`: Performs a discretization of continuous exposures.

- `ilod`: Imputation of under-LOD values of exposures.

- `imputation`: Imputation of missing values of exposures.

- `mexwas`: Performs a Multiple-EXposure-Wide Association Study.

- `normalityTest`: Test the normality of each exposure.

- `pca`: Performs a PCA

- `phenotypeNames`: Getter to obtain the phenotypes's names.

- `plotFamily`: Draws a boxplot or accumulated-bar plot for each exposure in a given family.

- `plotHistogram`: Draws an histogram of a given continuous exposure or a pie chart if a given categorycal exposure.

- `plotLOD`: Draws a barchart with the amount of under-LOD values.

- `plotMissings`: Draws a bar-plot with the amount of missing values.

- `standardize`: Standardization of exposures.

- `Summary`: Summary of both continuous and categorical exposures

- `tableLOD`: Returns a vector with the number of under-LOD values per exposure.

- `tableMissings`: Returns a vector with the number of missing values per exposure.

- `trans`: Transformation of exposures.

### Slots

`assayData`

  Contains the exposures matrix with column number equal to `nrow(phenoData)` (see eSet, AssayData).

`featureData`

  Contains the description of the exposures including the family where they belong (see eSet, AnnotatedDataFrame).

`phenoData`

  Contains the phenotypes or variables experimenter-supplied (see eSet, AnnotatedDataFrame).

### See Also

`readExposome` to create an `ExposomeSet` from files, `loadExposome` to create an `ExposomeSet` from `data.frames`

[Package rexposome version 1.8.0 Index]