MathGroup Archive 2011

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

Search the Archive

Re: Nasti jitter in plotsize

  • To: mathgroup at smc.vnet.net
  • Subject: [mg118012] Re: Nasti jitter in plotsize
  • From: Heike Gramberg <heike.gramberg at gmail.com>
  • Date: Fri, 8 Apr 2011 04:15:39 -0400 (EDT)

You could set ImagePadding to an absolute value, i.e.

Manipulate[
 Plot[Sin[1/k x], {x, -k \[Pi], k \[Pi]}, ImagePadding -> 10], {k, 1, 
  10}]

Heike.


On 7 Apr 2011, at 13:06, roby wrote:

> Dear all,
> 
> Manipulate[Plot[Sin[1/k x], {x, -k \[Pi], k \[Pi]}], {k, 1, 10}]
> 
> I want to scale my x-axis simultaneously with my function (no I dont
> want to zoom the function)
> What happens is a small jitter of the plot size.
> This jitter exactly happens when the most left (most right) tick mark
> value coincidences with the plot border.
> I tried to remove the first and last tick of the final plot to avoid
> the problem.
> 
> I was able to extract the ticks and remove the very first and last
> ones of the plot like this:
> With[{k=3},
> (Plot[Sin[1/k], {x, - k \[Pi], k \[Pi]}] // First@AbsoluteOptions[#,
> Ticks] &) /.
> (Ticks -> {x_, y_}) :> (Ticks -> {Rest@Most[x], Rest@Most@y})
> ]
> 
> but I failed by automaticaly (not by hand) replacing the original
> ticks with with the modifyed ticks in the plot.
> 
> 
> Any suggestion ?
> 
> btw constraining the PlotSize and similar dose not help.
> 
> Cheers Robert
> 



  • Prev by Date: Re: ProgressIndicator and ParallelTable problem :(
  • Next by Date: Re: Nasti jitter in plotsize
  • Previous by thread: Nasti jitter in plotsize
  • Next by thread: Re: Nasti jitter in plotsize