metaGE.heatmap {metaGE} | R Documentation |
Draw the heatmap to see markers effects across environments.
Description
The function metaGE.heatmap displays the heatmap of the zscores, the estimated marker effects or the pvalues of each markers (in rows) in each environments (in columns).
Usage
metaGE.heatmap(
Data,
Prefix = "Z.",
EnvGroups = NULL,
QTLsVarName = NULL,
RowOrder = TRUE,
ColOrder = TRUE,
ShowDendrogram = FALSE,
Colors = c("red", "black", "green"),
Main = ""
)
Arguments
Data |
A dataset containing the zscores, the effects or the pvalues of each marker (in rows) in each environment (in columns), as obtained from metaGE.fit. |
Prefix |
The prefix of the score to display in the heatmap: 'Z.' for the zscores, 'EFFECT.' for the effects and 'PVAL.' for the pvalues.('Z.' by default) |
EnvGroups |
A dataset containing the names of the environments (in the first column) and the groups to which the environments belong (in the second column). (optional) |
QTLsVarName |
The name of the column indicating to which QTL the marker belongs. (optional) |
RowOrder |
A boolean specifying whether to reorder the markers or not. (TRUE by default) |
ColOrder |
A boolean specifying whether to reorder the environments or not. (TRUE by default) |
ShowDendrogram |
A boolean specifying wether to show the clustering of the rows and/or the columns. (FALSE by default) |
Colors |
A vector of three colors corresponding to the color scale of the Heatmap. |
Main |
The main to display.(optional) |
Value
The heatmap
Examples
require(dplyr)
# Import the data
data("metaData")
# Compute the inter-environment correlation matrix
matCorr <- metaGE.cor(metaData, Threshold = 0.8)
# Fit the Fixed Effect model
FeDF <- metaGE.fit(metaData, matCorr, Method = "Fe")
# Control the FDR (here Benjamini-Hochberg)
Alpha <- 0.05
Signif <- FeDF$PVALUE %>% p.adjust(method = "BH") %>% `<`(Alpha) %>% which
# Draw the z-scores heatmap of the significant markers
heatmap <- metaGE.heatmap(Data = FeDF[Signif,],
Prefix = "Z.")