rrBlupRotation: rrBlupRotation - linear transformation for the adjusted means...

Description Usage Arguments Details Value Author(s) See Also Examples

Description

This function implements the rotation described in Piepho et al. (2011) thus the assumption of R = I sigma2 in function rrBlupM6 is satisfied.

Usage

1
rrBlupRotation(y, X = matrix(1,nrow=n, ncol=1), Z, R)

Arguments

y

Numeric vector with adjusted means of the genotypes.

X

Design matrix of fixed effects, including the intercept. By default, this is an all 1 column vector for the intercept.

Z

Matrix assigning marker genotypes to phenotypes in y. The dimension of the matrix must be no. phenotypes (rows) times no. markers (columns). The coding must be 1 and -1 for the two homozygous genotypes.

R

Variance-covariance structure of the adjusted means

Details

Please see Piepho et al. (2011) and Schulz-Streeck et al. (2012) for details on the rotation approach. The variance-covariance structure R can, for example, be obtained with the function vcov from fitted (mer) model objects, or with the output option COV for the LSMEANS statement in PROC MIXED in SAS.

Value

A list with three components

y_tilda

Numeric vector with the rotated adjusted means,

X_tilda

Rotated design matrix of the fixed effects and

Z_tilda

Rotated design matrix with the marker information

Author(s)

Torben Schulz-Streeck, Boubacar Estaghvirou, Frank Technow

See Also

rrBlupMethod6,rrBlupM6

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
## simulate a small data set (250 observations, 300 markers)
set.seed(3421475)
N <- 250
M <- 300

Z <- matrix(sample(c(1,-1),N * M, replace = TRUE),
            nrow = N,
            ncol = M)

## marker effects
u <- rnorm(M, 0, sqrt(1/M))

sig2e <- 1
y <- Z %*% u + rnorm(N,0,sqrt(sig2e))

## simulate a random variance-covariance structure of the adjusted means
## (Note that this is just for demonstration purposes, the values are
## non-sensical!)
R <- matrix(rnorm(N*N),N,N) 
diag(R) <- abs(diag(R))
R <- R + t(R)


## rotate
out_r <- rrBlupRotation(y, Z = Z, R = R)

## use rotated y,X and Z for computing marker effects and set sig2e = 1
out_RRBLUP_m6_r <- rrBlupM6(y = out_r$y_tilda,
                            X = out_r$X_tilda,
                            Z = out_r$Z_tilda,
                            sig2e = 1,
                            chunks = 4)

rrBlupMethod6 documentation built on May 2, 2019, 7:38 a.m.