From 22c11d5dbc118881f9cfd7c9c2ac9711295a0f16 Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Fri, 24 Mar 2017 15:24:04 +0100 Subject: Suppress error messages in dr(c)fit, maintenance - Checking examples fails if error messages in dr(c)fit stemming from failed fits are printed - Delete trailing whitespace - Update packaging --- R/drdata.R | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'R/drdata.R') diff --git a/R/drdata.R b/R/drdata.R index eda1249..dc741a6 100644 --- a/R/drdata.R +++ b/R/drdata.R @@ -3,7 +3,7 @@ drdata <- function(substances, experimentator = "%", db = "cytotox", organism = "Vibrio fischeri", endpoint = "Luminescence", whereClause = "1", ok = "'ok','no fit'") { - if (require("RODBC")) { + if (requireNamespace("RODBC")) { channel <- RODBC::odbcConnect(db,uid="cytotox",pwd="cytotox",case="tolower") slist <- paste(substances,collapse="','") if (db == "cytotox") { @@ -21,7 +21,7 @@ drdata <- function(substances, experimentator = "%", db = "cytotox", type <- organism } } - + query <- paste("SELECT conc,",responsetype,",unit,experimentator,substance,",testtype, ",ok FROM ", db, " WHERE substance IN ('", slist,"') AND experimentator LIKE '", -- cgit v1.2.1