Displaying 20 results from an estimated 2000 matches similar to: "4PL algorithm"
2002 Sep 27
2
How to apply SSfpl with binary data
Dear R-help subscribers
Would you tell me how to apply SSfpl with binary data as below?
Unfortunately, there is not the EXAMPLE in help(SSfpl) for binary data but for quantitative data(Chick).
V1: dose
V2: log-transformed dose
V3: response (rate)
V1 V2 V3
1 0.775 -0.2548922 0.1666667
2 5.000 1.6094379 0.8148148
3 10.000 2.3025851 0.5000000
4 20.000 2.9957323
2001 May 01
0
SSfpl self-start sometimes fails... workaround proposed
Hello,
nls library provides 6 self-starting models, among them: SSfp, a four
parameters logistic function. Its self-starting procedure involves several
steps. One of these steps is:
pars <- as.vector(coef(nls(y ~ cbind(1, 1/(1 + exp((xmid - x)/exp(lscal)))),
data = xydata, start = list(lscal = 0), algorithm = "plinear")))
which assumes an initial value of lscal equal to 0. If lscal
2017 Oct 20
1
Error messages using nonlinear regression function (nls)
Thank you Martin.
If I understand correctly, OP could do
wheat.list <- nlsList(Prop ~ SSfpl(end, A, B, xmid, scal), data=wlg)
or add some small value to all zeroes
wlg$prop < -wlg$Prop+1e-7
wheat.list <- nlsList(prop ~ SSlogis(end,Asym, xmid, scal), data=wlg)
which gives fairly reasonable results.
plot(augPred(wheat.list))
Am I correct?
Cheers
Petr
> -----Original Message-----
2004 Aug 10
0
Check failed after compilation (PR#7159)
Full_Name: Madeleine Yeh
Version: 1.9.1
OS: AIX 5.2
Submission from: (NULL) (151.121.225.1)
After compiling R-1.9.1 on AIX 5.2 using the IBM cc compiler, I ran the
checks. One of them failed. Here is the output from running the check solo.
root@svweb:/fsapps/test/build/R/1.9.1/R-1.9.1/tests/Examples:
># ../../bin/R --vanilla < stats-Ex.R
R : Copyright 2004, The R
2017 Oct 20
0
Error messages using nonlinear regression function (nls)
>>>>> PIKAL Petr <petr.pikal at precheza.cz>
>>>>> on Fri, 20 Oct 2017 06:33:36 +0000 writes:
> Hi
> Keep your messages in the list, you increase your chance to get some answer.
> I changed your data to groupedData object (see below), but I did not find any problem in it.
> plot(wlg)
> gives reasonable picture and I am
2011 Aug 09
1
nls, how to determine function?
Hi R help,
I am trying to determine how nls() generates a function based on the
self-starting SSlogis and what the formula for the function would be.
I've scoured the help site, and other literature to try and figure
this out but I still am unsure if I am correct in what I am coming up
with.
**************************************************************************
dat <-
2005 Jul 13
1
Fieller's Conf Limits and EC50's
Folks
I have modified an existing function to calculate 'ec/ld/lc' 50 values
and their associated Fieller's confidence limits. It is based on
EC50.calc (writtien by John Bailer) - but also borrows from the dose.p
(MASS) function. My goal was to make the original EC50.calc function
flexible with respect to 1) probability at which to calculate the
expected dose, and 2) the link
2009 Aug 19
3
Fitting a logistic regression
Hello,
I have this data:
Time AMP
0 0.2000000
10 0.1958350
20 0.2914560
40 0.6763628
60 0.8494534
90 0.9874526
120 1.0477692
where AMP is the concentration of this metabolite with time. If you plot
the data, you can see that it could be fitted using a logistic
regression. For this purpose, I used this code:
AMP.nls <- nls(AMP~SSlogis(Time,Asym, xmid, scal), data
2011 May 27
1
Put names in the elements of lapply result
Dear list,
I am running some linear regressions through lapply,
>lapply(c('EMAX','EC50','KOUT','GAMMA'),function(x)confint(lm(get(x)~RR0,dataset2)))
I got results like
[[1]]
2.5 % 97.5 %
(Intercept) 0.6595789212 0.8821691261
RR0 -0.0001801771 0.0001489083
[[2]]
2.5 % 97.5 %
(Intercept) -63.83694930
2003 Aug 20
0
4 parameter logistic model
Hi, I am trying to fit a 4-parameter logistic model to
my gradient data using nls. I tried to specify the
model directly in the nls formula and also tried to
use the self-start function SSfpl. For the following
data, the first method worked, but the second didn't.
I thought both ways were equivalent, can anyone tells
me why?
>
2003 Feb 22
2
4-parameter logistic model
Dear R users
I'm a new user of R and I have a basic question about the 4-parameter
logistic model. According to the information from Pinheiro & Bates the model
is:
y(x)=theta1+(theta2-theta1)/(1+exp((theta3-x)/theta4)) ==
y(x)=A+(B-A)/(1+exp((xmid-input)/scal))
from the graph in page 518 of the book of the same authors (mixed models in
S) theta 1 corresponds to the horizontal asymptote
2006 Dec 30
2
Error: cannot take a sample larger than the population
Hi,
In Splus7 this statement
xlrmN1 <- sample(c(0,1,2),400 ,prob=c(0.02 ,0.93 ,0.05 ))
worked fine, but in R the interpreter reports that the length of the
vector to chose c(0,1,2) is shorter than the size of many times I want
to be selected from the vector c(0,1,2).
Any good reason?
See below the error.
> xlrmN1 <- sample(c(0,1,2),400 ,prob=c(0.02 ,0.93 ,0.05 ))
Error in
2008 Nov 26
1
Request for Assistance in R with NonMem
Hi
I am having some problems running a covariate analysis with my
colleage using R with the NonMem program we are using for a graduate
school project. R and NonMem run fine without adding in the
covariates, but the program is giving us a problem when the covariate
analysis is added. We think the problem is with the R code to run the
covariate data analysis. We have the control stream, R code
2011 Sep 13
0
nls, the four parameter logistic equation, and prediction band
The error msg is telling you that R cannot evaluate the loss function, so you should not
expect answers.
You might try examining the data -- Are there NA or Inf entries?
Or prepare a dataframe with just X and Y, sort by X and graph.
Then check the nls computations by sampling, say, every 100 X's to give you a dataset with
about 160 observations. If that doesn't work, it is at least
2011 Sep 13
0
nls, the four parameter logisitc equation, and prediction band
I have uploaded a datafile that contains the following two variables: time
(X value) and response (Y value). This is a fairly extensive file (with >
16000 entries). I have two questions:
1. I want to use the following equation to regress Y on X: Y-hat = min +
(max-min)/(1 + (X/EC50)^Hillslope).
Here is my R command:
nlsout <- nls(Y ~ (0 - (100-0)/(1 + (X/EC50)^hill)), start=c(EC50=125,
2007 Dec 14
1
garch function in tseries package
I am wondering how to run 'garch' function of 'tseries' package in R2.6.1.
I installed R2.3.1 and R2.6.1 in my PC (Windows XP Home) and run a
following simple GARCH function in both versions:
>garch(dSP[1:300], order = c(1,1))
where 'dSP' is daily return series of a stock index.
R2.6.1 can not finish calculation and also I can not stop the
2009 May 20
2
drc results differ for different versions
Hello,
We use drc to fit dose-response curves, recently we discovered that
there are quite different standard error values returned for the same
dataset depending on the drc-version / R-version that was used (not
clear which factor is important)
On R 2.9.0 using drc_1.6-3 we get an IC50 of 1.27447 and a standard
error on the IC50 of 0.43540
Whereas on R 2.7.0 using drc_1.4-2 the IC50 is
2010 Jul 12
1
What is the degrees of freedom in an nlme model
Dear all,
I want to do a F test, which involves calculation of the degrees of
freedom for the residuals. Now say, I have a nlme object "mod.nlme". I
have two questions
1.How do I extract the degrees of freedom?
2.How is this degrees of freedom calculated in an nlme model?
Thanks.
Jun Shen
Some sample code and data
=================================================================
2005 May 26
0
Confidence intervals for prediction based on the logistic equation
Greetings,
We are performing a meta-analysis of mink pup survival data versus
chemical concentration. We have modeled percent survival successfully
using nls as shown below and the plot. What we need to do is construct a
confidence interval on the concentration at which we get 50% survival
(aka the EC50, although we may want other percent survivals in the
future). My first question is, what seems
2008 Feb 19
0
nlsList - Error in !unlist(lapply(coefs, is.null))
Howdee,
I am able to fit a 4-parameter logistic growth curve to a dataset which
comprise many individuals (using R v. 2.3.1). Yet, if I want to obtain the
parameters for each individual (i.e., for each 'id') using nlsList, then I
obtain an Error message which I have trouble interpreting. Any advice as to
how I can solve this problem?
Thanks for your time,
Marc
> reg <-nls(mass ~