K-Science.info

K-Science.info

Line Plot:

Stacks Image 8988

Example 1: Ice Core Data

 ggplot(Ice.ice.baby,aes(x=gas_age,y=temp))+
     geom_point(size=5)+
     ggtitle("Ice Core Data")+
     geom_line(aes(y = temp), colour="blue", size=2)+
     scale_x_continuous(name="Gas Age (Ka)", ) +
     scale_y_continuous(name="Estimated Temperature (C)", )+
     geom_point(size=5)+
     geom_smooth()+
     theme(plot.title = element_text(size = 40, face = "bold")) +
     theme(axis.title.y = element_text(size = 30, angle = 90)) +
     theme(axis.title.x = element_text(size = 30, angle = 360)) +
     theme(legend.title = element_text(size=20, face = "bold")) +
     theme(legend.text = element_text(size=20, face = "italic")) +
     theme(plot.title = element_text(hjust = 0.5))
     
Stacks Image 181

Example 1: Ice Core Data 2

     I.got.gas<-rev(Ice.ice.baby$gas_age)
     
     ggplot(Ice.ice.baby,aes(x= I.got.gas,y = CO2, colour=I.got.gas))+
     ggtitle("Ice Core Data")+
     geom_line(aes(y = CO2), colour="red", size=2,stat="identity")+
     geom_point(aes(y = CO2),colour="red", size=1)+
     geom_line(aes(y = temp), colour="blue", size=2,stat="identity")+
     geom_point(aes(y = temp),size=1, colour="blue")+
     geom_line(aes(y = CH4), colour="green", size=2,stat="identity")+
     geom_point(aes(y = CH4, ),size=1, colour="green")+
     scale_colour_manual(name="Key",values=c("CO2"= "red", "CH4"="green", "temp"="blue"))+
     scale_x_continuous(name="Gas Age (Ka)", ) +
     scale_y_continuous(name="CO2 Concentration (ppm)", )+
     theme(plot.title = element_text(size = 40, face = "bold")) +
     theme(axis.title.y = element_text(size = 30, angle = 90)) +
     theme(axis.title.x = element_text(size = 30, angle = 360)) +
     theme(legend.title = element_text(size=20, face = "bold")) +
     theme(legend.text = element_text(size=20, face = "italic")) +
     theme(plot.title = element_text(hjust = 0.5))+
     theme(legend.title = element_text(face = "bold")) 
Stacks Image 12972
Stacks Image 189