if (interactive()) {
x <- get_example_data()
## Typical example with one GWAs result table, one DE result table and
## one table of candidate genes
hidecan_plot(gwas_list = x[["GWAS"]],
de_list = x[["DE"]],
can_list = x[["CAN"]],
score_thr_gwas = -log10(0.0001),
score_thr_de = -log10(0.005),
log2fc_thr = 0,
label_size = 2)
## Example with two sets of GWAS results
hidecan_plot(gwas_list = list(x[["GWAS"]], x[["GWAS"]]),
score_thr_gwas = 4)
## Example with two sets of DE results, with names
hidecan_plot(de_list = list("X vs Y" = x[["DE"]],
"X vs Z" = x[["DE"]]),
score_thr_de = -log10(0.05),
log2fc_thr = 0)
## Set limits on all chromosomes (to "zoom in" to the 10-20Mb region)
hidecan_plot(gwas_list = x[["GWAS"]],
de_list = x[["DE"]],
can_list = x[["CAN"]],
score_thr_gwas = -log10(0.0001),
score_thr_de = -log10(0.005),
log2fc_thr = 0,
label_size = 2,
chrom_limits = c(10e6, 20e6))
## Set limits on some chromosomes only
hidecan_plot(gwas_list = x[["GWAS"]],
de_list = x[["DE"]],
can_list = x[["CAN"]],
score_thr_gwas = -log10(0.0001),
score_thr_de = -log10(0.005),
log2fc_thr = 0,
label_size = 2,
chrom_limits = list("ST4.03ch00" = c(10e6, 20e6),
"ST4.03ch02" = c(15e6, 25e6)))
}
Run the code above in your browser using DataLab