Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2006

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Ordinate in Plot Command

  • To: mathgroup at
  • Subject: [mg70291] Re: Ordinate in Plot Command
  • From: dimmechan at
  • Date: Thu, 12 Oct 2006 05:36:49 -0400 (EDT)
  • References: <egi15s$j3i$>

Try the following

Plot[x + 0.5, {x, 0, 1}, AxesOrigin -> {0, 0}, PlotRange -> {{-0.001,
1}, {0.001, 1.5}},
  Ticks -> {Range[0, 1, 0.2], Range[0, 1.4, 0.2]}]
(*plot to be displayed*)

and you get what you want.

However there is one shortcoming: the point {0,0} is not displayed.
I cannot find a way to display it.

Based on my experience it is better to work with Frame:

Plot[x + 0.5, {x, 0, 1}, Frame -> True, Axes -> False, PlotRange ->
{{-0.001, 1},
 {-0.001, 1.5}}]
(*plot to be displayed*)

Nevertheless, if you still want a plot with axes you can use Frame as
(this modification of Frame option seems to be undocumanted in the
Help Browser; I learn it from David Park)

Plot[x + 0.5, {x, 0, 1}, Frame -> {True,True,False,False}, Axes ->
False, PlotRange ->
{{-0.001, 1}, {-0.001, 1.5}}]
(*plot to be displayed*)


Robert M. Mazo wrote:
> When one forces the axes origin to go through {0,0}
> (AxesOrigin->{0,0}) in a Plot command, and the function being plotted
> has no values near y = 0, Mathematica leaves a blank instead of
> printing  the lower part of the y axis. Try
> Plot[x+.5, {x, 0, 1}, AxesOrigin ->{0,0}, PlotRange ->All]
> to see what I mean in a simple case.  Does anyone know an easy
> workaround for this problem?
> Of course, you can have Mathematica draw in the missing part of the
> axis with a separate command, Line[{0,0}, {0, ordinate of point where
> y axis begins to print], but then you have to figure out where to put
> in the tick marks and labels.  This is doable, but a nuisance.  What I
> am looking for is a way to tell Mathematica "don't drop the lower part
> of the axis."
> Bob

  • Prev by Date: Re: convergence checking
  • Next by Date: Re: Automate datafitting to a series of parameterized function
  • Previous by thread: Re: Ordinate in Plot Command
  • Next by thread: FourierCosTransform