wtCheckConfiguration.Rd
Checks a WTAQ configuration for its structure
wtCheckConfiguration(configuration, part = "complete", dbg = TRUE)
configuration | WTAQ configuration (complete) or sub-configuration (general, aquifer, rainage, times, solution, pumpwell, obswell) |
---|---|
part | one of c("complete", "general", "aquifer", "drainage", "times", "solution", "pumpwell", "obswell") |
dbg | if TRUE, debug messages are shown, else not. |
Error message or "" if no error occurred
# Generate default configuration cconf <- wtConfigure() # Check (complete) configuration. No error -> ok wtCheckConfiguration(cconf)#> Checking "general" configuration... ok. #> Checking "aquifer" configuration... ok. #> Checking "drainage" configuration... ok. #> Checking "times" configuration... ok. #> Checking "solution" configuration... ok. #> Checking "pumpwell" configuration... ok. #> Checking "obswell" configuration... #> - Checking config of observation well 1...ok. #> - Checking config of observation well 2...ok.ok.#> [1] ""# Generate default observation well configuration oconf <- wtConfigureObservationWell() # Check "obswell" configuration. No error -> ok wtCheckConfiguration(oconf, "obswell")#> [1] ""# Set obswells in complete configuration (forgetting that obswells must be # a list!): cconf$obswells <- oconf # Check (complete) configuration again # -> Error when "Checking config of observation well 1". wtCheckConfiguration(cconf)#> Checking "general" configuration... ok. #> Checking "aquifer" configuration... ok. #> Checking "drainage" configuration... ok. #> Checking "times" configuration... ok. #> Checking "solution" configuration... ok. #> Checking "pumpwell" configuration... ok. #> Checking "obswell" configuration... #> - Checking config of observation well 1... #> *** Configuration "obswell" does not contain all of these required elements: "irun", "obname", "iows", "idpr", "r", "z1", "z2", "zp", "rp", "xll", "tsobs".#> [1] "\n*** Configuration \"obswell\" does not contain all of these required elements: \"irun\", \"obname\", \"iows\", \"idpr\", \"r\", \"z1\", \"z2\", \"zp\", \"rp\", \"xll\", \"tsobs\".\n"