Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, is already up and running.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: RE: Calculate confidence intervals for log-log models

From   Nick Cox <>
Subject   Re: st: RE: Calculate confidence intervals for log-log models
Date   Tue, 5 Mar 2013 20:38:44 +0000

Sorry, I am still fuzzy on what you want, but it's easier to say what
you appear to be doing wrong.

1. -lincom- is for linear combinations, hence its name. Powering isn't
included. Stata is giving you a somewhat cryptic error message, but
what you are asking is outside the range of what it does. (I should
have mentioned that earlier.)

2. Also, a multiplicative change in x is an additive change in ln x.
Perhaps you want what you say, but when I think about power functions,
I think about multiplying (dividing) the original variables by some
constant and consequently about what is equivalent adding
(subtracting) on a logarithmic scale.

There is likely to be an easier answer in terms of elasticity in
-margins- somewhere.


On Tue, Mar 5, 2013 at 8:26 PM, Jason Ferris <> wrote:
> Hi Nick,
> Sorry for my ambiguity.  And thank you for your response.
> Before, I start writing my own code to do this I will attempt to clarify.
> Yes I transformed both Y and X with a natural log transformation ln(y) and ln(x)
> I then regress lny on lnx
> OLS example of a result:
> ------------------------------------------------------------------------------
>          lny |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
> -------------+----------------------------------------------------------------
>          lnx |   2.105722   .0817271    25.77   0.000     1.942802    2.268642
>        _cons |  -3.032146   .4274653    -7.09   0.000    -3.884282   -2.180009
> ------------------------------------------------------------------------------
> To calculate a 10% change on lnx (with confidence intervals) when I type
> lincom 1.1^lnx - I get the message 'not possible with text'
> I would like to construct a table highlighting percentage changes in lny with a series of percentage changes (10,25...) in lnx

On Tue, 5 Mar 2013 12:49:28 +0000 Nick Cox <> wrote:

> Not really clear what you are doing but I guess that you are
> transforming first. Either way, something like
> _b[ln(y)]
> makes no sense to Stata as
> ln(y)
> can't be a variable name.
> I fear you need to write your own code.

On Tue, Mar 5, 2013 at 11:30 AM, Jason Ferris <> wrote:

>> I have run a series of log-log OLS models - ln(y)=ln(x)+cons - and would like to present a table of percentage change at 10%, 25%, 50%, & 75% with corresponding changes in the confidence intervals.
>> Is there a way to do this in Stata or a ado file that I could utilise.
>> When trying to use lincom (.e.g., 1.1^_b[ln(x)] - I get a 'not possible with test' error.  What are the alternatives besides doing it all by hand?
*   For searches and help try:

© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index