Skip to content

Commit

Permalink
Merge pull request #177 from AgroCares/fix-waterretention
Browse files Browse the repository at this point in the history
Hotfix/v2.0.4
  • Loading branch information
SvenVw authored Jan 11, 2023
2 parents 4b97216 + 75a9f78 commit 50ef0c2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: OBIC
Type: Package
Title: Calculate the Open Bodem Index (OBI) Score
Version: 2.0.3
Version: 2.0.4
Authors@R: c(
person("Sven", "Verweij", email = "[email protected]", role = c("aut","cre")),
person("Gerard", "Ros", email = "[email protected]", role = "aut"),
Expand Down
4 changes: 4 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# OBIC 2.0.4 2023-01-11
### Fixed
* Fixes calculation of `field capacity` at `calc_waterretention`

# OBIC 2.0.3 2023-01-11
### Fixed
* Fixes plotting of regime curve in workabilty vignette #149
Expand Down
2 changes: 1 addition & 1 deletion R/waterretention.R
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ calc_waterretention <- function(A_CLAY_MI,A_SAND_MI,A_SILT_MI,A_SOM_LOI,

# convert from % to mm (wp) and mm (fc)
dt[,wp := wp * p.depth * 1000]
dt[,fc := wp * p.depth * 1000]
dt[,fc := fc * p.depth * 1000]

# select Water Retention index
if(type=='wilting point'){dt[,value := wp]}
Expand Down

0 comments on commit 50ef0c2

Please sign in to comment.