grav2 <- read_cross2(system.file("extdata", "grav2.zip", package="qtl2"))
map <- insert_pseudomarkers(grav2$gmap, step=1)
probs <- calc_genoprob(grav2, map, error_prob=0.002)
out <- scan1(probs, grav2$pheno)
plot_scan1_heatmap(out, map)
# make the y-axis quantitative
y <- grav2$phenocovar$time
plot_scan1_heatmap(out, map, y=y, ylab=colnames(grav2$phenocovar))
# plot with colors white -> darkslateblue, and with color scale
col <- colorRampPalette(c("white", "darkslateblue"))(256)
zlim <- c(0, maxlod(out))
layout(cbind(1,2), width=c(3,1))
plot_scan1_heatmap(out, map, y=y, ylab=colnames(grav2$phenocovar),
col=col, zlim=zlim)
plot_colorscale(col=col, zlim=zlim)
Run the code above in your browser using DataLab