Commit 05d4d99f authored by David Watkins's avatar David Watkins
Browse files

NA_real_

parent b06d1f8c
...@@ -210,7 +210,7 @@ importWaterML2 <- function(input, asDateTime=FALSE, tz="UTC") { ...@@ -210,7 +210,7 @@ importWaterML2 <- function(input, asDateTime=FALSE, tz="UTC") {
uom = uom, comment = comment) uom = uom, comment = comment)
df_use <- df_vars[sapply(df_vars, function(x){length(x) > 0 && !all(is.na(x))})] df_use <- df_vars[sapply(df_vars, function(x){length(x) > 0 && !all(is.na(x))})]
df <- data.frame(df_use, stringsAsFactors = FALSE) df <- data.frame(df_use, stringsAsFactors = FALSE)
if(!"value" %in% names(df)) {df$value <- as.numeric(NA)} if(!"value" %in% names(df)) {df$value <- NA_real_}
#from the default metadata section #from the default metadata section
#append to existing attributes if they aren't empty #append to existing attributes if they aren't empty
mdAttribs <- list(defaultQualifier=defaultQuals, defaultUOM=defaultUOM, mdAttribs <- list(defaultQualifier=defaultQuals, defaultUOM=defaultUOM,
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment