Re: [R] Fitting a curve to weibull distribution in R using nls

2015-10-14 Thread Aditya Bhatia
Thank you for the amazing response. You are right;I definitely have to study a bit more. I am just trying to copy the procedure in a paper so I didn't give it much thought. for point (a) : yes the data is binned counts; and my aim is to find out which curve best approximates these counts. I am go

Re: [R] Fitting a curve to weibull distribution in R using nls

2015-10-14 Thread Therneau, Terry M., Ph.D.
On 10/14/2015 05:00 AM, r-help-requ...@r-project.org wrote: I am trying to fit this data to a weibull distribution: My y variable is:1 1 1 4 7 20 7 14 19 15 18 3 4 1 3 1 1 1 1 1 1 1 1 1 and x variable is:1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

Re: [R] Fitting a curve to weibull distribution in R using nls

2015-10-14 Thread peter dalgaard
There's a number of issues with this: (a) your data appear to be binned counts, not measurements along a curve. (b) The function you are trying to fit is the Weibull _density_ This has integral 1, by definition, whereas any curve anywhere near your y's would have integral near sum(y)=127 (c) SSw

Re: [R] Fitting a curve to weibull distribution in R using nls

2015-10-13 Thread Aditya Bhatia
Yes. I do.I'm trying to repeat the methodology of a paper. They have fitted their data to a weibull curve and so I want to do the same too, but I'm unable to figure out how.. On Wed, Oct 14, 2015, 9:44 AM David Winsemius wrote: > > On Oct 13, 2015, at 2:42 PM, Aditya Bhatia wrote: > > > I am try

Re: [R] Fitting a curve to weibull distribution in R using nls

2015-10-13 Thread David Winsemius
On Oct 13, 2015, at 2:42 PM, Aditya Bhatia wrote: > I am trying to fit this data to a weibull distribution: > > My y variable is:1 1 1 4 7 20 7 14 19 15 18 3 4 1 3 1 1 1 > 1 1 1 1 1 1 > > and x variable is:1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 > 19 20 21 22 23 24

[R] Fitting a curve to weibull distribution in R using nls

2015-10-13 Thread Aditya Bhatia
I am trying to fit this data to a weibull distribution: My y variable is:1 1 1 4 7 20 7 14 19 15 18 3 4 1 3 1 1 1 1 1 1 1 1 1 and x variable is:1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 The plot looks like this:http://i.stack.imgur.com/FrIKo.png and