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

Re: st: Minor bug


From   [email protected] (Jean Marie Linhart, StataCorp.)
To   [email protected]
Subject   Re: st: Minor bug
Date   Thu, 29 May 2003 15:49:57 -0500

"Dupont, William" <[email protected]> asked:

> I believe there is a bug in the blcolor option of the twoway rarea
> command.  The following do file and comments illustrates the bug and
> explains why this might confuse point and click users.  Please let
> me know if I am misinterpreting the intent of this option.
>
>
> *********************
> *  rarea.do
> *  Evidence of a bug in the blcolor option of the twoway rarea command
> *
> set scheme s2color
> set more on
> set obs 5
> gen x = _n
> generate high = 3 + x
> generate low = x
> twoway rarea low hi x, bcolor(gs14)                       //Comment 1
> more
> twoway (rarea high low x)                                 //Comment 2
> more
> twoway (rarea high low x, bfcolor(gs14))                  //Comment 3
> more
> twoway (rarea high low x, blcolor(none) bfcolor(gs14))    //Comment 4
> (bug)
> more
> twoway (rarea high low x, blcolor(gs14) bfcolor(gs14))    //Comment 5
> ************************
<stuff snipped>
>
> 4.  The Color pull down box controls the color of the outline.  This
> command results from choosing Color = none.  I believe that this command
> should have the same effect as the command on the //Comment 1 line.
> Instead it gives a blank graph.  I assume that this is a bug.

This is a feature, of the sort where Stata lets you do something that
no one in her right mind would want to do.

When you specify the outline color as -none-, you are saying there is
no outline.  When there is no outline, there is no interior because
the interior is defined as the stuff within the outline.  It's like
trying to have a glass of milk without the glass.  In this case the
interior color leaks out and just disappears.  You don't have to mop
it up off the floor, but it is the same idea.

What is more useful is to specify the fill color as none and to just
get the outline, but the capability exists for both.

To get the same outline and fill color, specify them both as gs14 as
in the Comment 5 graph.

Hope that helps.

--Jean Marie
[email protected]
*
*   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