Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


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

Re: st: Hard min & max cutoffs on Y-axis using -marginsplot-


From   Nick Cox <[email protected]>
To   "[email protected]" <[email protected]>
Subject   Re: st: Hard min & max cutoffs on Y-axis using -marginsplot-
Date   Tue, 24 Dec 2013 11:10:36 +0000

-marginsplot- is a command, not a function.

It's general in Stata graphics that you can't omit data by using
-xsc()- or -ysc()- or -yla()- or -xla()-. You can extend the graph
that way, but there isn't a side-effect of constraining the graph
because the labels specified don't cover the entire range of the data.
Just imagine the complaints if that were true.

My guess is that what you want is programmable but not easily.

Nick
[email protected]


On 23 December 2013 22:38, Andrew Kim <[email protected]> wrote:
> Hello!
>
> I am having a problem using the -marginsplot- function in STATA.  I want to "zoom-in" on a certain area of the graph.  In other words, I set a hard min and max on the Y- and X-axes.  The code looks something similar to:
>
> .marginsplot, ytitle("my title", size(medsmall) margin(small)) ylabel(.02 .06, labsize(small) angle(horizontal)) xlabel(0(15)90, labsize(small))
>
> I am getting the graph to look almost the way I want it to be shown.  The X-axis min and max are perfect - begins at 0 and cuts-off at 90 with 15 unit increments.  The Y-axis only shows .02 and .06 however, there are curves that dip far below .02 and STATA automatically scales the graph to show those lines.  If you can imagine, the .02 rests in the middle of the Y-Axis and there is a lot of white space below.
>
> I just want to code in an option to zoom in on a specific area to see clearer differentiation.  Does anyone know how (or if its possible) to do this?
>
> Thanks!
> Andrew
>
>
>
> *
> *   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/

*
*   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–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index