Repository 'insect_phenology_model'
hg clone https://eddie.galaxyproject.org/repos/greg/insect_phenology_model

Changeset 60:a3bdf0d35d1d (2017-11-13)
Previous changeset 59:1d4e864b7720 (2017-11-13) Next changeset 61:82668ca72b08 (2017-11-13)
Commit message:
Uploaded
modified:
insect_phenology_model.R
b
diff -r 1d4e864b7720 -r a3bdf0d35d1d insect_phenology_model.R
--- a/insect_phenology_model.R Mon Nov 13 12:14:26 2017 -0500
+++ b/insect_phenology_model.R Mon Nov 13 12:26:48 2017 -0500
[
@@ -35,7 +35,7 @@
     for (i in 1:num_days) {
         # Get the day of the year from the current row
         # of the temperature data for computation.
-        doy <- temperature_data[c(i:i), 4]
+        doy <- temperature_data[i, 4]
         theta <- 0.2163108 + 2 * atan(0.9671396 * tan(0.00860 * (doy - 186)))
         phi <- asin(0.39795 * cos(theta))
         # Compute the length of daylight for the day of the year.
@@ -234,7 +234,7 @@
     # All the days included in the input temperature dataset.
     for (row in 1:opt$num_days) {
         # Get the integer day of the year for the current row.
-        doy <- temperature_data[c(row:row), 4]
+        doy <- temperature_data[row, 4]
         # Photoperiod in the day.
         photoperiod <- daylight_length_vector[row]
         temp.profile <- get_temperature_at_hour(latitude, temperature_data, daylight_length_vector, row, opt$num_days)