From 18b13d3122eaa4f803795dfa2cb5ba951c8354f6 Mon Sep 17 00:00:00 2001 From: "(no author)" <(no author)@d1b72e20-2ee0-0310-a1c4-ad5adbbefcdc> Date: Wed, 1 Sep 2004 05:05:20 +0000 Subject: Fixed some mistakes in the help files, and took away the dependency on the defunct nls package in the function drfit. git-svn-id: http://kriemhild.uft.uni-bremen.de/svn/drfit@4 d1b72e20-2ee0-0310-a1c4-ad5adbbefcdc --- R/drfit.R | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'R/drfit.R') diff --git a/R/drfit.R b/R/drfit.R index c3fc945..a3b8a1b 100644 --- a/R/drfit.R +++ b/R/drfit.R @@ -23,13 +23,12 @@ drdata <- function(substances, experimentator = "%", db = "cytotox", drfit <- function(data, startlogEC50 = NA, lognorm = TRUE, logis = FALSE, linearlogis = FALSE, b0 = 2, f0 = 0) { - library(nls) - substances <- levels(data$substance) - unit <- levels(as.factor(data$unit)) - logisf <- function(x,x0,b,k=1) - { - k / (1 + (x/x0)^b) - } + substances <- levels(data$substance) + unit <- levels(as.factor(data$unit)) + logisf <- function(x,x0,b,k=1) + { + k / (1 + (x/x0)^b) + } linearlogisf <- function(x,k,f,mu,b) { k*(1 + f*x) / (1 + ((2*f*(10^mu) + 1) * ((x/(10^mu))^b))) -- cgit v1.2.1