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

From |
"Randy Akee " <akee@iza.org> |

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

Subject |
st: Non-Linear Least Squares Programming Question |

Date |
Wed, 15 Aug 2007 15:44:49 +0200 |

Hi, I have a program that I want to use with the NL (non-linear least squares) command in Stata. I just have a simple question with regard to Stata v.9, for my objective function that gets "replaced" in the NL program, is it possible to have the Left Hand side and the ride hand side both be matrices? Typically, I have seen examples (in the stata manual and other people's do files), where the right hand side is simply a single equation. For instance: capture program drop nltest program define nltest version 9.0 if "`1'"== { global S_1 b1 b2 b3 } replace `1'=$b1*X+exp($b2*$b3) end nl test data1 X etc. . . I want to know if Stata v.9 can handle a matrix on both the right hand side and left hand side (can data1 and X be matrices?) in the line above that begins with "replace". I have several equations that I would like to fit with the same parameters. I know Stata v.10 has the NLSUR command, I just want to know if I should wait for this version. Thanks, Randy ------------------------------------------------- Randall K. Q. Akee, Ph.D. Research Associate IZA - Forschungsinstitut zur Zukunft der Arbeit GmbH IZA - Institute for the Study of Labor P.O. Box 7240, 53072 Bonn, Germany Schaumburg-Lippe-Str. 5-9, 53113 Bonn, Germany Phone: +49 (228) 3894-306; Fax: +49 (228) 3894-510 E-Mail: akee@iza.org Web: http://www.iza.org Registered Office Bonn, District Court of Bonn, HRB 7745 Represented by: Prof. Dr. Klaus F. Zimmermann (Director) ------------------------------------------------- * * 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**:**st: RE: Non-Linear Least Squares Programming Question***From:*"Nick Cox" <n.j.cox@durham.ac.uk>

- Prev by Date:
**Re: st: Date & if function** - Next by Date:
**Re: st: factor analysis - interpreting the results, inclusion of dp variable** - Previous by thread:
**st: lcolor not allowed** - Next by thread:
**st: RE: Non-Linear Least Squares Programming Question** - Index(es):

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