Statalist The Stata Listserver


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

st: CES with nl


From   "Rodolfo Coelho Prates" <[email protected]>
To   [email protected]
Subject   st: CES with nl
Date   Fri, 8 Jun 2007 10:09:41 -0300 (BRT)

Dear listers,

I�ve tried estimate a nested CES production function with three factors:
capital (k), labor (l) and land (n).

The nested CES production function is:

y=e{a[bk^(-c)+(1-b)l^(-c)]^(d/c)+(1-a)n^d}^(-1/d)

I used nl command and wrote the follow instructions:

program define nlces1

            if "`1'" == "?" {
                global S_1 "e a b c d"
		global a=1
                global b=1
                global c=1
                global d=1
		global e=.5
                global S_2 "CES with multiplicative error"
                exit
            }

       	replace `1' =
$e*(($a*($b*k^(-$c))+(1-$b)*l^(-$c))^($d/$c)+(1-$a)*n^(-$d))^(-1/$d)


    end

    nl ces1 y

The Stata calculates the interections and print this message:
"cannot calculate derivatives"

What can I do?

Thanks a lot,

Rodolfo

*
*   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/



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