From e51e063564bffcb75dbb6ab7a364704c8d8e992e Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Mon, 12 Dec 2016 21:24:24 +0100 Subject: Fix reading .out for acronyms containing numbers --- R/TOXSWA_cwa.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'R/TOXSWA_cwa.R') diff --git a/R/TOXSWA_cwa.R b/R/TOXSWA_cwa.R index c5ddce9..45189f8 100644 --- a/R/TOXSWA_cwa.R +++ b/R/TOXSWA_cwa.R @@ -236,7 +236,7 @@ TOXSWA_cwa <- R6Class("TOXSWA_cwa", } else { # Get the substance name(s) sub_lines <- grep(".*0.000.*ConLiqWatLayCur_", outfile[1:50], value = TRUE) - substances <- gsub(".*ConLiqWatLayCur_(.*?) *[0-9].*", "\\1", sub_lines) + substances <- gsub(".*ConLiqWatLayCur_(.*?) +[0-9].*", "\\1", sub_lines) if (!substance %in% c("parent", substances)) { stop("No data for substance ", substance, " present in the .out file.") } -- cgit v1.2.1