From e26e2ab9b9bc614f0a728fccaa1dfb36a96f8be4 Mon Sep 17 00:00:00 2001 From: Matt Paul Date: Tue, 10 Dec 2024 21:43:47 -0500 Subject: [PATCH] add title --- PlottingInR/inst/doc/Plotting.Rmd | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/PlottingInR/inst/doc/Plotting.Rmd b/PlottingInR/inst/doc/Plotting.Rmd index e086a35..b271350 100644 --- a/PlottingInR/inst/doc/Plotting.Rmd +++ b/PlottingInR/inst/doc/Plotting.Rmd @@ -146,7 +146,7 @@ vioplot(length_millimeters~common_name, data = salmon, use.cols=F, main="Distrib - Lets make a heatmap. The data we currently have read in is not right for a heatmap. Luckily we have another example data set that corresponds to what we have been looking at: salmon_mercury.csv. Read it in and inspect the object. When you read the object in, set the row names as column 1. ```{R} -library(pheatmap) + salmon_mercury <- read.csv("data/salmon_mercury.csv", row.names = 1) ``` @@ -154,6 +154,7 @@ salmon_mercury <- read.csv("data/salmon_mercury.csv", row.names = 1) - Lets make a heatmap. The data we currently have read in is not right for a heatmap. Luckily we have another example data set that corresponds to what we have been looking at: salmon_mercury.csv. Read it in and inspect the object. ```{R} +library(pheatmap) pheatmap(salmon_mercury) ``` @@ -192,6 +193,6 @@ library(RColorBrewer) my_pal <- colorRampPalette(c("Blue","White","Red"))(60) -pheatmap(salmon_mercury, scale ="row", breaks = seq(-1.5,1.5,0.05), color = my_pal, cluster_cols = F, "Z-scores of Mercury levels (ppm) in Salmon species over time") +pheatmap(salmon_mercury, scale ="row", breaks = seq(-1.5,1.5,0.05), color = my_pal, cluster_cols = F, main="Z-scores of Mercury levels (ppm) in Salmon species over time") ``` \ No newline at end of file