View source: R/Violin_by_genotype.R
Viol.by.gen | R Documentation |
This tool creates violin plots corresponding to each genotype.
Viol.by.gen(qt, g, trait_name = "qt trait", title = "")
qt |
A numeric vector. |
g |
An integer vector. |
trait_name |
A string. |
title |
A string. |
A violin plot
n_val <- 50000L
geno_vec <- sample(c(0, 1, 2), size = n_val, replace = TRUE)
qt_vec <- rnorm(n_val) * (1.3^geno_vec) + 1 * geno_vec
Viol.by.gen(qt_vec, geno_vec)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.