diff --git a/DESCRIPTION b/DESCRIPTION index 79ee26e..786c7bf 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -2,10 +2,10 @@ Package: APSIM Type: Package Title: General Utility Functions for the 'Agricultural Production Systems Simulator' -Version: 0.9.2 -Date: 2017-07-24 +Version: 0.9.4 +Date: 2019-05-22 Author: Justin Fainges -Maintainer: Justin Fainges +Maintainer: Dean Holzworth LazyData: true Description: Contains functions designed to facilitate the loading and transformation of 'Agricultural Production Systems Simulator' diff --git a/R/MetFunctions.R b/R/MetFunctions.R index eadb8fb..a284629 100644 --- a/R/MetFunctions.R +++ b/R/MetFunctions.R @@ -268,8 +268,8 @@ insertTavAmp <- function(met){ data$meanDayT <- (data$maxt + data$mint) / 2 mmt <- plyr::ddply(data, "month", function(df) mean(df$meanDayT)) if (nrow(mmt) != 12) print("WARNING: At least 12 months of data is required to generate tav and amp. Values may be inaccurate.") - met@tav <- max(mmt$V1) - min(mmt$V1) - met@amp <- mean(mmt$V1) + met@amp <- max(mmt$V1) - min(mmt$V1) + met@tav <- mean(mmt$V1) return(met) } diff --git a/README.md b/README.md index 7ab32e8..86ca4da 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,14 @@ A package containing general purpose utility functions for loading and manipulat Release Notes ============= +### 0.9.4 + +- + +### 0.9.3 + +- TAV and AMP calculations have been incorrect (swapped) + ### 0.9.2 - loadApsim has new option: skipEmpty, which will skip output files with no data.