Re: [R] how to interpolate a plot with a logistic curve

From: Simone Gabbriellini <simone.gabbriellini_at_gmail.com>
Date: Thu, 6 Dec 2007 12:29:51 +0100

Dear Christian,

it works great, and it is simple to understand, thank you very much.

just a detail, is it possible to plot just the fitted curve and not the data? it's because I would like to have data in black and the fitted curve in red.. I don't know how to pick up the single parts, if I simply wrote

> plot(simone.m1, log="", col="red")

everything became red..

thank in advance,
Simone

Il giorno 06/dic/07, alle ore 09:00, Christian Ritz ha scritto:

> Dear Simone,
>
> you can use the package 'drc' to fit a logistic model, that is a non-
> linear regression model based on the equation c+(d-c)/(1+exp(b(x-
> e))), to your data (below named 'simone'):
>
>
> ## Fitting a 4-parameter logistic model (also called Boltzmann model)
> simone.m1 <- drm(size~x, data=simone, fct=B.4())
>
> ## Plotting the data together with the fitted curve
> plot(simone.m1, log="")
>
>
> The fit is not great due to the bend.
>
>
> Christian
>



R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu 06 Dec 2007 - 11:31:38 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 06 Dec 2007 - 12:30:17 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.