Hi,
have you been working with ggplot2 before? If so, then you can use the geom_tile to create something like the graphic you posted.
Here an example:
library(dplyr)
library(ggplot2)
# create a tibble with one column for depth and one for the value
depth<-seq(from=0, to=5,by=0.5)
value<-sample(1:20,11)
df<-tibble(depth,value)
# plot the heatmap
df%>%ggplot(aes(x=1,fill=value,y=depth))+
geom_tile()+
# add label inside the tiles:
geom_label(aes(label=value),fill="white")+
# flip y axis:
scale_y_reverse(breaks = depth)+
# remove x axis lable
theme( axis.text.x=element_blank())
From a data frame like this:
depth value
<dbl> <int>
1 0 2
2 0.5 16
3 1 12
4 1.5 7
5 2 14
6 2.5 19
7 3 13
8 3.5 15
9 4 8
10 4.5 18
11 5 4
You will get this graphic: