diff insect_phenology_model.R @ 56:2fd7b1f7153d draft

Uploaded
author greg
date Mon, 13 Nov 2017 12:03:29 -0500
parents c24b519ad05e
children 1d4e864b7720
line wrap: on
line diff
--- a/insect_phenology_model.R	Mon Nov 13 11:50:11 2017 -0500
+++ b/insect_phenology_model.R	Mon Nov 13 12:03:29 2017 -0500
@@ -613,8 +613,8 @@
 # Subfigure 2: population size by generation
 title <- paste("BSMB total population by generation :", opt$location, ": Lat:", latitude, ":", start_date, "to", end_date, sep=" ")
 plot(day.all, g0, main=title, type="l", ylim=c(0, max(g2)), axes=F, lwd=2, xlab="", ylab="", cex=3, cex.lab=3, cex.axis=3, cex.main=3)
-lines(day.all, g1, lwd = 2, lty = 1, col = 2)
-lines(day.all, g2, lwd = 2, lty = 1, col = 4)
+lines(day.all, g1, lwd = 2, lty = 1, col=2)
+lines(day.all, g2, lwd = 2, lty = 1, col=4)
 axis(1, at=c(1:12) * 30 - 15, cex.axis=3, labels = c("Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"))
 axis(2, cex.axis=3)
 leg.text <- c("P", "F1", "F2")
@@ -622,21 +622,21 @@
 if (opt$se_plot == 1) {
     # Add SE lines to plot
     # SE for adults
-    lines (day.all, g0 + g0.se, lty = 2)
-    lines (day.all, g0 - g0.se, lty = 2) 
+    lines (day.all, g0+g0.se, lty=2)
+    lines (day.all, g0-g0.se, lty=2) 
     # SE for nymphs
-    lines (day.all, g1 + g1.se, col = 2, lty = 2)
-    lines (day.all, g1 - g1.se, col = 2, lty = 2)
+    lines (day.all, g1+g1.se, col=2, lty=2)
+    lines (day.all, g1-g1.se, col=2, lty=2)
     # SE for eggs
-    lines (day.all, g2 + g2.se, col = 4, lty = 2)
-    lines (day.all, g2 - g2.se, col = 4, lty = 2)
+    lines (day.all, g2+g2.se, col=4, lty=2)
+    lines (day.all, g2-g2.se, col=4, lty=2)
 }
 
 # Subfigure 3: adult population size by generation
 title <- paste("BSMB adult population by generation :", opt$location, ": Lat:", latitude, ":", start_date, "to", end_date, sep=" ")
 plot(day.all, g0a, ylim=c(0, max(g2a) + 100), main=title, type="l", axes=F, lwd=2, xlab="", ylab="", cex=3, cex.lab=3, cex.axis=3, cex.main=3)
-lines(day.all, g1a, lwd = 2, lty = 1, col = 2)
-lines(day.all, g2a, lwd = 2, lty = 1, col = 4)
+lines(day.all, g1a, lwd = 2, lty = 1, col=2)
+lines(day.all, g2a, lwd = 2, lty = 1, col=4)
 axis(1, at=c(1:12) * 30 - 15, cex.axis=3, labels = c("Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"))
 axis(2, cex.axis=3)
 leg.text <- c("P", "F1", "F2")
@@ -644,14 +644,14 @@
 if (opt$se_plot == 1) {
     # Add SE lines to plot
     # SE for adults
-    lines (day.all, g0a + g0a.se, lty = 2)
-    lines (day.all, g0a - g0a.se, lty = 2) 
+    lines (day.all, g0a+g0a.se, lty=2)
+    lines (day.all, g0a-g0a.se, lty=2) 
     # SE for nymphs
-    lines (day.all, g1a + g1a.se, col = 2, lty = 2)
-    lines (day.all, g1a - g1a.se, col = 2, lty = 2)
+    lines (day.all, g1a+g1a.se, col=2, lty=2)
+    lines (day.all, g1a-g1a.se, col=2, lty=2)
     # SE for eggs
-    lines (day.all, g2a + g2a.se, col = 4, lty = 2)
-    lines (day.all, g2a - g2a.se, col = 4, lty = 2)
+    lines (day.all, g2a+g2a.se, col=4, lty=2)
+    lines (day.all, g2a-g2a.se, col=4, lty=2)
 }
 
 # Turn off device driver to flush output.