From the GBLUP solutions and a centered SNP matrix backsolve SNP effects

backsolveSNPeff(Z, g)

Arguments

Z

Centered marker matrix (dominance deviations must also be centered)

g

The solutions (blups, i.e. GEBVs) from the GBLUP model

Value

matrix of SNP effects matching RR-BLUP / SNP-BLUP

Examples

A<-kinship(M,type="add")
#> Error in kinship(M, type = "add"): object 'M' not found
trainingDF %<>% dplyr::mutate(ga=factor(as.character(id), levels=rownames(A)), gd=ga)
#> Error in trainingDF %<>% dplyr::mutate(ga = factor(as.character(id), levels = rownames(A)), gd = ga): could not find function "%<>%"
gblup<-mmer(pheno~1, random=~vs(ga,Gu = A), weights=WT, data=trainingDF,verbose = T)
#> Error in mmer(pheno ~ 1, random = ~vs(ga, Gu = A), weights = WT, data = trainingDF, verbose = T): could not find function "mmer"
ga<-as.matrix(gblup$U$`u:ga`$pheno,ncol=1)
#> Error in as.matrix(gblup$U$`u:ga`$pheno, ncol = 1): object 'gblup' not found
Za<-centerDosage(M)
#> Error in is.data.frame(x): object 'M' not found
snpeff<-backsolveSNPeff(Za,ga)
#> Error in tcrossprod(Z): object 'Za' not found