meanIntensityByScanChrom {GWASTools} | R Documentation

## Calculate Means \& Standard Deviations of Intensities

### Description

Function to calculate the mean and standard deviation of the intensity for each chromosome for each scan.

### Usage

    meanIntensityByScanChrom(intenData, vars = c("X", "Y"),
                             snp.exclude = NULL, verbose = TRUE)

### Arguments

`intenData` | `IntensityData` object. Chromosomes are expected to be in contiguous blocks.
`vars` | Character vector with the names of one or two intensity variables.
`snp.exclude` | An integer vector containing SNPs to be excluded.
`verbose` | Logical value specifying whether to show progress information.

### Details

The names of two intensity variables in `intenData` may be supplied. If two variables are given, the mean of their sum is computed as well. The default is to compute the mean and standard deviation for X and Y intensity.

### Value

A list with two components for each variable in "vars": 'mean.var' and 'sd.var'. If two variables are given, the first two elements of the list will be mean and sd for the sum of the intensity variables:

`mean.intensity` | A matrix with one row per scan and one column per chromosome containing the means of the summed intensity values for each scan and chromosome.
`sd.intensity` | A matrix with one row per scan and one column per chromosome containing the standard deviations of the summed intensity values for each scan and chromosome.
`mean.var` | A matrix with one row per scan and one column per chromosome containing the means of the intensity values for each scan and chromosome.
`sd.var` | A matrix with one row per scan and one column per chromosome containing the standard deviations of the intensity values for each scan and chromosome.

### Author(s)

Cathy Laurie

### See Also

`IntensityData`, `mean`, `sd`

### Examples

    file <- system.file("extdata", "illumina_qxy.gds", package="GWASdata")
    gds <- GdsIntensityReader(file)
    intenData <- IntensityData(gds)

    meanInten <- meanIntensityByScanChrom(intenData)
    close(intenData)

[Package GWASTools version 1.28.0 Index]