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, statalist.org is already up and running.


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

RE: st: RE: Invisible axis


From   Ricardo Ovaldia <ovaldia@yahoo.com>
To   statalist@hsphsun2.harvard.edu
Subject   RE: st: RE: Invisible axis
Date   Tue, 11 May 2010 05:45:05 -0700 (PDT)

I think Nick is missing the point. I am not using the over() option, in which case it would be easy to eliminate the x-axis. I have a series of variable that are to be plotted on the same bar plot. Something like my previous example:

. graph bar  price  weight ...


Ricardo Ovaldia, MS
Statistician 
Oklahoma City, OK


--- On Tue, 5/11/10, Nick Cox <n.j.cox@durham.ac.uk> wrote:

> From: Nick Cox <n.j.cox@durham.ac.uk>
> Subject: RE: st: RE: Invisible axis
> To: statalist@hsphsun2.harvard.edu
> Date: Tuesday, May 11, 2010, 7:05 AM
> But that's not necessary. 
> 
> sysuse auto 
> graph bar mpg, over(foreign)
> graph bar mpg, over(foreign, axis(off)) 
> graph bar mpg, over(foreign, axis(off))
> plotregion(lcolor(none))
> 
> shows that you don't _need_ to use the editor or rewrite as
> -twoway- for this purpose. 
> 
> Nick 
> n.j.cox@durham.ac.uk
> 
> 
> Ricardo Ovaldia
> 
> Thank you
> 
> 
> --- On Mon, 5/10/10, Martin Weiss <martin.weiss1@gmx.de>
> wrote:
> 
> 
> > Ricardo can also take a cue from NJC`s post at
> > http://www.stata.com/statalist/archive/2009-04/msg00856.html
> > and construct
> > the whole thing from scratch, which does allow him to
> get
> > rid of the
> > unwanted axis:
> > 
> > 
> > ***********
> > sysuse auto, clear
> > graph bar price weight, ysc(off) /* 
> > */ showyvar legend(off) name(mygr, replace)
> > 
> > collapse price weight
> > gen byte one=1
> > gen byte two=2
> > 
> > tw (bar price one) (bar weight two), /* 
> > */  ysc(off) ysc(range(0 6200)) xsc(off)
> > ***********
> > 
> > 
> > HTH
> > Martin
> > 
> > -----Original Message-----
> > From: owner-statalist@hsphsun2.harvard.edu
> > [mailto:owner-statalist@hsphsun2.harvard.edu]
> > On Behalf Of Scott Merryman
> > Sent: Montag, 10. Mai 2010 22:03
> > To: statalist@hsphsun2.harvard.edu
> > Subject: Re: st: RE: Invisible axis
> > 
> > You can use the graph editor:
> > 
> > . graph bar  price  weight, ysc(off) 
> > showyvar legend(off)
> > 
> > . gr_edit .varaxis.style.editstyle
> linestyle(color(none))
> > editcopy
> > 
> > Scott
> > 
> > 
> > On Mon, May 10, 2010 at 2:43 PM, Ricardo Ovaldia
> <ovaldia@yahoo.com>
> > wrote:
> > > Thank you Nick and Martin
> > > The suggestion works for the scatter plot but for
> the
> > bar graph, I can get
> > rid of the y-axis but not the x-axis:
> > >
> > > . sysuse auto, clear
> > > . graph bar  price  weight, ysc(off)
>  showyvar
> > legend(off)
> > >
> > > . graph bar  price  weight, ysc(off)
>  xsc(off)
> > showyvar legend(off)
> > > xscale(off) not allowed, xaxis1 does not exist
> 
> *
> *   For searches and help try:
> *   http://www.stata.com/help.cgi?search
> *   http://www.stata.com/support/statalist/faq
> *   http://www.ats.ucla.edu/stat/stata/
> 


      

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


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