normalize.proportion: Normalize data to proportions

View source: R/integration.R

normalize.proportionR Documentation

Normalize data to proportions

Description

For a given variable, normalize the data values in an electrophoresis object to proportions of the total. After normalization the sum of the variable for each sample is 1.

Usage

normalize.proportion(electrophoresis, variable, lower.marker.spread = 5)

Arguments

electrophoresis

An electrophoresis object.

variable

The name of a variable in electrophoresis$data.

lower.marker.spread

Proportion to scale the width of the lower marker peak (passed to between.markers).

Details

Only data points between the markers are considered in the total. If there is no upper marker, all data points above the lower marker are considered.

Value

A vector whose length equals nrow(electrophoresis$data), in which each value is an observation of the given variable normalized by the total for that sample, or NA if the observation is not between the markers.

See Also

differential.scale


jwfoley/bioanalyzeR documentation built on Aug. 1, 2023, 4:46 a.m.