[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

From |
"Maarten Buis" <M.Buis@fsw.vu.nl> |

To |
<statalist@hsphsun2.harvard.edu> |

Subject |
RE: st: RE: broken stick (piecewise linear) regression |

Date |
Tue, 24 May 2005 14:36:06 +0200 |

Dear Keith My post would do what you want, but normal spline regression is far far far more stable. So Nick was right (as usual) in pointing you to -mkspline-. I would only use -nl- if the location of the knot were my primary interest. I would still prefer to use somewhat plausible locations (like equally spaced knots) rather than -nl-, even if I did not know the exact location, if the exact locations of the knots are not of substantial interest (as is usually the case). If you just want to fit a flexible line through your data you could have a look at -locpoly-. Hope this helps, Maarten -----Original Message----- From: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu]On Behalf Of keith Farnsworth Sent: dinsdag 24 mei 2005 14:13 To: statalist@hsphsun2.harvard.edu Subject: Re: st: RE: broken stick (piecewise linear) regression Thanks, Nick, but I looked at mkspline before and realised that it specifically requires the knot point, whereas the problem I have, addressed by Bacon and Watts, is to find the best fit knot point i.e - estimating the transition between two intersecting straight lines. Unless there is something you can do with mkspline that is not in the documentation, I don't see that it can fit the knot. Any other idea? Keith. On Tuesday, May 24, 2005, at 12:55 Europe/Dublin, Nick Cox wrote: > . search mkspline > > should help. See both entries. > > Nick > n.j.cox@durham.ac.uk > > keith Farnsworth > >> I intend to fit a broken stick model following Bacon and Watts >> "Estimating the transition between two intersecting straight lines", >> Biometrika 1971. I have seen code for this to use the S or R >> package's >> nls, which I suspect uses maximum likelihood (but not sure) [see >> http://www.biostat.wustl.edu/archives/html/s-news/2000-04/ >> msg00215.html]. >> >> I am not an S user, I am a Stata enthusiast! >> However, I found no reference to this kind of model in Stata >> searches. >> I hope someone with more experience than me can explain how >> Stata will >> implement the Bacon and Watts model. > > * > * For searches and help try: > * http://www.stata.com/support/faqs/res/findit.html > * http://www.stata.com/support/statalist/faq > * http://www.ats.ucla.edu/stat/stata/ > > Dr Keith Farnsworth Lecturer in Mathematical and Behavioural Ecology Queens University Belfast Medical Biology Centre 97 Lisburn Road Belfast BT9 7BL Northern Ireland phone +44 (0)2890 272352 fax +44 (0)2890 236505 * * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/ * * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/

**Follow-Ups**:**Re: st: RE: broken stick (piecewise linear) regression***From:*keith Farnsworth <k.farnsworth@qub.ac.uk>

- Prev by Date:
**Re: st: RE: broken stick (piecewise linear) regression** - Next by Date:
**st: RE: the factors of the product of prime numbers** - Previous by thread:
**st: RE: broken stick (piecewise linear) regression** - Next by thread:
**Re: st: RE: broken stick (piecewise linear) regression** - Index(es):

© Copyright 1996–2016 StataCorp LP | Terms of use | Privacy | Contact us | What's new | Site index |