pseudovalidationR: Performs 'pseudovalidation' to select the best lambda value...

View source: R/pseudovalidationR.R

pseudovalidationRR Documentation

Performs ‘pseudovalidation’ to select the best \lambda value in lassosum (without PLINK bfile)

Description

Performs ‘pseudovalidation’ to select the best \lambda value in lassosum (without PLINK bfile)

Usage

pseudovalidationR(genotype.mat, beta, cor)

Arguments

genotype.mat

A genotype matrix (coded 0/1/2)

beta

The matrix of estimated \betas

cor

The vector of correlations (r)

Details

A function to calculate

f(\lambda)=\beta'r/\sqrt{\beta'X'X\beta}

where X is the standardized genotype matrix divided by \sqrt n, and r is a vector of (shrunken) correlations.

Value

the results of the pseudovalidation, i.e. f(\lambda)

Note

  • The number of rows in beta and the length of cor should be the same as the number of columns in genotype.mat.


SeojinHwang/scadsum documentation built on June 30, 2023, 10:52 p.m.