|
|
Re: Is it possible to query current plot range values (or have
Posted:
Jul 4, 2010 6:10 AM
|
|
On 04.07.2010 09:10, Leo Alekseyev wrote: > Some of my plots contain vertical lines for alignment. To make sure > the lines extend from the top to the bottom of the plot frame, I > typically give those lines large values for +y and -y coordinates. > This has an unfortunate side effect that the directive PlotRange->All > now considers my line to be a part of the plot, and rescales the plot > range to display it in its entirety. Is there a way to (a) either > make PlotRange->All ignore this line somehow or (b) set the +y and -y > coordinates of the line to match the current plot range?.. > > Thanks in advance to anyone who might clarify this... > --Leo > Hi Leo, you may use scaled coordinates that run from 0..1: Plot[Sin[x], {x, 0, 10}, Epilog -> {Line[{Scaled@{0.5, 0}, Scaled@{0.5, 1}}]}] Note that you must also give the x coordinate in the 0..1 scale. cheers, Daniel
|
|