Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: adding lines to graph


From   "b. water" <[email protected]>
To   [email protected]
Subject   Re: st: adding lines to graph
Date   Wed, 21 May 2003 12:54:33 +0000

Hello Scott,

Sorry about the language. Titres (UK) = titers (US) = "the strength of a solution or the concentration of a substance (as an antibody) in solution as determined by titration" as defined by Webster's dictionary.

I have a go at your stata commands. I do not know whether that's what's Clara's after and it's not what I have in mind but thank you for sharing the lateral thinking idea/principle of overlaying two graphs rather than trying to find out from the manual all the options that might've been required to do that.

Cheers,
bw



From: "Scott Merryman" <[email protected]>
Reply-To: [email protected]
To: <[email protected]>
Subject: Re: st: adding lines to graph
Date: Tue, 20 May 2003 21:00:01 -0500

----- Original Message -----
From: "b. water" <[email protected]>
To: <[email protected]>
Sent: Tuesday, May 20, 2003 4:10 PM
Subject: RE: st: adding lines to graph


> i was faced with this problem in the past. what i am suggesting to you is
a
> 'cheat' method but nevertheless pragmatic and works. it is not
> 'stata'tiscally correct but at that time or even now i knew no better but
> here it is anyway. up to you whether you want to deploy it or not.
>
> copy your graph and paste as metafile into either word or powerpoint and
> then drew a square object over the pertinent area of the graph. rt click
on
> the object, choose format object, click transparent and choose 5% grey (or
> color of your liking). that's it.
>
> hope this is helpful.
>
> i know that in the past, mentioning the micros*** raise some antibody
titres
> in this list. so my apology before hand. if anyone else knows how to do
the
> shading in stata, do tell. even i would be interested to know too.
>
> cheers,
> bw

First, what are titres?

Second, I'm not sure if you can shade sub-regions of the graph but you can
shade part of the graph with -twoway area- laid over a line graph. The
basic idea is to create another series that only contains observations for
the shaded regions.

For example, if you wanted to shade the recessions of a GNP timeseries you
could do the following.

preserve
sysuse gnp96,clear
gen recession = d.gnp if d.gnp < 0
replace rec = 0 if rec ==.
twoway (line d.gnp date ) (area recession date)
restore

Hope this helps,
Scott



*
* 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/
_________________________________________________________________
MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*. http://join.msn.com/?page=features/virus

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