dat = data.frame(read.csv("c:/Users/Saman/Onedrive/Desktop/Mast467/Data/all_dat.csv",sep=","))
dat=subset(dat, select=-X)
library(ggplot2)
## Warning: package 'ggplot2' was built under R version 4.0.5
T = ggplot(dat) + 
  geom_point(aes(x=Year, y=Tmax))+
  stat_summary(aes(x = Year,y = Tmax,group=1), fun=median, colour="red", geom="line",group=1)+
  ggtitle("Median T Max for Region 8 (2016,2018-2021)")+
  stat_summary(aes(x = Year,y = Tmax,group=1), fun=median, colour="red", geom="point",group=1, size = 3)+
  theme(legend.position = "none")
T

D = ggplot(dat) + 
  geom_point(aes(x=Year, y=D_Tmax))+
  stat_summary(aes(x = Year,y = D_Tmax,group=1), fun=median, colour="red", geom="line",group=1)+
  ggtitle("Median Depth of TMax for Region 8 (2016,2018-2021)")+
  stat_summary(aes(x = Year,y = D_Tmax,group=1), fun=median, colour="red", geom="point",group=1, size = 3)+
  theme(legend.position = "none")
D

S = ggplot(dat) + 
  geom_point(aes(x=Year, y=S_Tmax))+
  stat_summary(aes(x = Year,y = S_Tmax,group=1), fun=median, colour="red", geom="line",group=1)+
  ggtitle("Median Salinity of TMax for Region 8 (2016,2018-2021)")+
  stat_summary(aes(x = Year,y = S_Tmax,group=1), fun=median, colour="red", geom="point",group=1, size = 3)+
  theme(legend.position = "none")
S