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]

From |
"Fiedler, James (JSC-SK)[USRA]" <james.fiedler-1@nasa.gov> |

To |
"statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu> |

Subject |
RE: st: RE: RE: RE: Graph: Control plot region- contract, not expand |

Date |
Thu, 16 Jun 2011 12:41:54 -0500 |

No problem. Glad to help. James ________________________________________ From: owner-statalist@hsphsun2.harvard.edu [owner-statalist@hsphsun2.harvard.edu] On Behalf Of Amanda Blakely Delp [abd35@georgetown.edu] Sent: Thursday, June 16, 2011 11:56 AM To: statalist@hsphsun2.harvard.edu Subject: Re: st: RE: RE: RE: Graph: Control plot region- contract, not expand Apologies, James- I didn't think your hint all the way through the first time. Thanks much; it did what I was looking for. On Thu, Jun 16, 2011 at 12:25 PM, Fiedler, James (JSC-SK)[USRA] <james.fiedler-1@nasa.gov> wrote: > By "range", do you mean y-axis? > If so, she says explicitly that she wants x-axis restriction. > If not, I'm not sure how we disagree. > > James > > ________________________________________ > From: owner-statalist@hsphsun2.harvard.edu [owner-statalist@hsphsun2.harvard.edu] On Behalf Of DE SOUZA Eric [eric.de_souza@coleurope.eu] > Sent: Thursday, June 16, 2011 11:10 AM > To: statalist@hsphsun2.harvard.edu > Subject: st: RE: RE: Graph: Control plot region- contract, not expand > > I don't think this is what Amanda wanted. The way I understand her, she wishes to estimate and fit a line over the range (a b) but only show the graph for that fit over the range (c d) where a < c and d < b > > > Eric de Souza > College of Europe > Brugge (Bruges), Belgium > http://www.coleurope.eu > > > -----Original Message----- > From: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] On Behalf Of Fiedler, James (JSC-SK)[USRA] > Sent: 16 June 2011 17:55 > To: statalist@hsphsun2.harvard.edu > Subject: st: RE: Graph: Control plot region- contract, not expand > > Hello, > > I haven't seen a response to this yet, so I'll take a stab at it. > > I'll have to make some assumptions, since you haven't explicitly said which command you are using. > > I assume you're using -twoway lfit-. > > Here's another option, which forgoes the convenience of -twoway lfit- but gives extra control: > > regress y x > predict yhat > twoway (scatter y x if x >= 1 & x <= 10) (line yhat x if x >= 1 & x <= 10, sort(x)) > > > James > > ________________________________________ > From: owner-statalist@hsphsun2.harvard.edu [owner-statalist@hsphsun2.harvard.edu] On Behalf Of Amanda Blakely Delp [abd35@georgetown.edu] > Sent: Thursday, June 16, 2011 10:13 AM > To: statalist@hsphsun2.harvard.edu > Subject: st: Graph: Control plot region- contract, not expand > > Hello all, > > I'm trying to create a fairly simple graph- just a scatterplot overlayed with a linear prediction. My problem is that I can't seem to control which area of the graph to display. I know I can expand the plot region, but there doesn't seem to be a similar code to force-contract it. > > All I care about is the 1-10 region on my scale (x-axis), where some outliers are outside of this region. Of course, if I drop these outliers, the graph region cooperates. Is it possible to crop the display region without dropping the observations which determine the behavior of the linear prediction? Like a way to force the command > "xscale(range(0 10)"? > > Ideally, I'd like to compare 2 graphs-- one with the outliers, and one without, but only along the smaller region of the x-axis. > > Many thanks- > Amanda > > * > * 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/ > > * > * 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/ > * * 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/

**References**:**st: Graph: Control plot region- contract, not expand***From:*Amanda Blakely Delp <abd35@georgetown.edu>

**st: RE: Graph: Control plot region- contract, not expand***From:*"Fiedler, James (JSC-SK)[USRA]" <james.fiedler-1@nasa.gov>

**st: RE: RE: Graph: Control plot region- contract, not expand***From:*DE SOUZA Eric <eric.de_souza@coleurope.eu>

**st: RE: RE: RE: Graph: Control plot region- contract, not expand***From:*"Fiedler, James (JSC-SK)[USRA]" <james.fiedler-1@nasa.gov>

**Re: st: RE: RE: RE: Graph: Control plot region- contract, not expand***From:*Amanda Blakely Delp <abd35@georgetown.edu>

- Prev by Date:
**Re: st: Missing standard error of constant term** - Next by Date:
**st: Pooled mean group and mean group estimator - xtpmg command** - Previous by thread:
**Re: st: RE: RE: RE: Graph: Control plot region- contract, not expand** - Next by thread:
**Re: st: RE: RE: Graph: Control plot region- contract, not expand** - Index(es):