[R] Fitting a function

Thomas Levine thomas.levine at gmail.com
Fri May 14 14:51:07 CEST 2010


x<-c(0.5,4,6,8,12)
y<-c(0.021,0.021,0.020,0.018,0.012)
lm(y~x)

2010/5/14 Dani Valverde <daniel.valverde at uab.cat>:
> Hello,
> It is a very naive question, but here it is. I have this values:
>
> x: 0.5 4 6 8 12
>
> y: 0.021 0.021 0.020 0.018 0.012
>
> I need to fit a function to them. How can I do it with R?
> Thank you so much!
>
> Dani
>
> --
> Daniel Valverde Saubí
>
> Grup de Biologia Molecular de Llevats
> Facultat de Veterinària de la Universitat Autònoma de Barcelona
> Edifici V, Campus UAB
> 08193 Cerdanyola del Vallès- SPAIN
>
> Tlf. +34 93 581 1910
> Fax: +34 93 581 1573
>
> ______________________________________________
> 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.
>



More information about the R-help mailing list