Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue12 #13

Merged
merged 2 commits into from
Nov 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions R/dw.R
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
#'
#' @param param parameter naam (als string)
#' @param gwl grondwaterlichaam (groundwaterbody)
#' @param data dataset met drempelwaardes. default is drempelwaardes dataset die
gilsvda marked this conversation as resolved.
Show resolved Hide resolved
#' bij het pakket zit

#' @return drempelwaarde per stof per grondwaterlichaam
#'
Expand All @@ -16,9 +18,8 @@



dw <- function(param,gwl) {
data(drempelwaarden)
x <- subset(drempelwaarden,select=param,gwbident==gwl)[[param]]
dw <- function(param,gwl,data=drempelwaarden) {
gilsvda marked this conversation as resolved.
Show resolved Hide resolved
x <- subset(data,select=param,gwbident==gwl)[[param]]
if(length(x)==0) {
warning("dw: no value found")
x <- NA
Expand Down
8 changes: 6 additions & 2 deletions R/getgwl.R
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
#'Help functie voor een lijst van de grondwaterlichamen
#'
#' @param data dataset met drempelwaardes. default is drempelwaardes dataset die
#' bij het pakket zit

#'@return een lijst van grondwaterlichaamnamen uit de LMG dataset
#'
#' @export

getgwl <- function() {
x <- as.character(unique(drempelwaarden$gwbident))
getgwl <- function(data=drempelwaarden) {
gilsvda marked this conversation as resolved.
Show resolved Hide resolved
x <- as.character(unique(data$gwbident))
x <- na.omit(x)
x <- sort(x)
attributes(x) <- NULL
Expand Down