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 on April 23, and its replacement, statalist.org is already up and running.


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

RE: st: Tobit graphics


From   "Kakouros, Nikolaos" <Nikolaos.Kakouros@umassmemorial.org>
To   "'statalist@hsphsun2.harvard.edu'" <statalist@hsphsun2.harvard.edu>
Subject   RE: st: Tobit graphics
Date   Thu, 27 Dec 2012 13:21:40 +0000

Ro'I,
Many thanks - that works great!  I changed recastci(rline) to (rarea) to get the same shaded CI effect as lfitci.

Now - is it possible to show this data on the same graph as the other dataset's scatter and lfitci?
I tried 
marginsplot, recast(line) recastci(rarea) addplot(twoway (scatter x y) (lfictci x2 y2) (scatter x2 y2))

I also tried
Twoway (marginsplot, recast(line) recastci(rarea) addplot(scatter x y)) (lfictci x2 y2) (scatter x2 y2)


with no luck...
Any suggestions?

Many thanks,

Nikos

-----Original Message-----
From: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] On Behalf Of Ro'i Zultan
Sent: Thursday, December 27, 2012 5:41 AM
To: statalist@hsphsun2.harvard.edu
Subject: Re: st: Tobit graphics

Hi Nikos,

I think the following should work for you:
tobit x y, ll(0)
margins, at(y=(0(10)100))
marginsplot, recast(line) recastci(rline) addplot(scatter x y)

With the margins parameters adjusted for your data.

Cheers,
Ro'i

2012/12/26 Kakouros, Nikolaos <Nikolaos.Kakouros@umassmemorial.org>
>
> Dear all,
>
> I have a set of data and using a twoway scatter and lfitci to show 
> graphically along with the least-squares regression line and 
> confidence intervals.
> Another set of data, however, is heavily censored with the dependent 
> variable hitting a floor at 0 (and about a third of values actually 
> being at zero).
> I noted the recent discussion on Tobit, chaired by Maarten Buis.
>
> I used tobit x y, ll(0)  for the regression but not sure how to 
> recreate the lfitci output (regression line and confidence intervals) 
> using the tobit regression info to produce the scatter graphic.
> Any help would be appreciated.
> With seasonal greetings,
>
> Nikos
>
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/

......................................................................
The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material.  Any review, transmission, re-transmission, dissemination or other use of, or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited.  If you received this in error, please contact the sender and delete the material from any computer.

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


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