Create variable for part 2:

temperature = read.csv("Temperature.csv")
library(ggplot2)
## Warning: package 'ggplot2' was built under R version 4.0.5
library(reshape2)
## Warning: package 'reshape2' was built under R version 4.0.5
temperature$decdate <- temperature$Year + temperature$dDay3 / 365

Plot 1, scatterplot of temperature and salinity overtime:

tempScatterplot = ggplot(temperature, aes(x = decdate, y = Salinity, color = Temperature)) 
tempScatterplot + geom_point(na.rm = TRUE) + ggtitle("Salinity Value Overtime") + xlab("Date") + ylab("Salinity")

Plot 2, a scatterplot of Salinity grouped into different areas:

facetplot = ggplot(temperature, aes(x = decdate, y = Salinity))
facetplot + geom_point(color = "green", na.rm = TRUE) + facet_wrap(~ Area) + ggtitle("Salinity by Area") +xlab("Date") + ylab("Salinity")

Plot 3, lineplot of salinity for each station grouped by area:

lineplot = ggplot(temperature, aes(x = Salinity, y = Station))
lineplot + facet_wrap(~ Area) + geom_line(aes(color = Station), na.rm = TRUE)

Optional plot, lineplot just for area ‘OS’

ggplot(subset(temperature, Area == "OS"),aes(x = Salinity, y = Station))+ geom_line(na.rm = TRUE) + geom_point(na.rm = TRUE) + ggtitle("OS Salinity by Station")