Description Usage Arguments Value Examples

View source: R/createphenotypeFunctions.R

The function scales the specified component such that the average column variance is equal to the user-specified proportion of variance.

1 | ```
rescaleVariance(component, propvar)
``` |

`component` |
[N x P] Phenotype matrix [double] where [N] are the number of samples and P the number of phenotypes |

`propvar` |
Number [double] specifying the proportion of variance that should be explained by this phenotype component |

If propvar != 0, a named list with the [N x P] matrix of the scaled component (component) and its scale factor [double] (scale_factor) else returns NULL

1 2 | ```
x <- matrix(rnorm(100), nc=10)
x_scaled <- rescaleVariance(x, propvar=0.4)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.