MathGroup Archive 2007

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

Search the Archive

Re: MatrixPlot: frame ticks starting with 0?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg77936] Re: MatrixPlot: frame ticks starting with 0?
  • From: Jean-Marc Gulliet <jeanmarc.gulliet at gmail.com>
  • Date: Wed, 20 Jun 2007 05:29:10 -0400 (EDT)
  • Organization: The Open University, Milton Keynes, UK
  • References: <f58dh8$8jo$1@smc.vnet.net>

robin.gruna at gmail.com wrote:
> Hi,
> I wonder how I can make MatrixPlot in Mathematica v6 to start the
> labeling of the frame ticks with 0? It allways starts the labeling
> with 1.
> Greetings,
> Robin

The base of indices for arrays, lists, vectors, etc., in Mathematica is 
one. That is why MatrixPlot starts the frame tick at 1.

You can control the tick marks with the option... *FrameTicks* as in

MatrixPlot[Table[Exp[Sin[x] + Cos[y]^2], {x, -8, 8, 0.4},
      {y, -8, 8, 0.4}],
  FrameTicks -> {{1, 10, 15, 20, 25} - 1, {12, 24}}]

MatrixPlot[Table[Exp[Sin[x] + Cos[y]^2], {x, -8, 8, 0.4},
      {y, -8, 8, 0.4}], FrameTicks -> {Range[0, 40, 10]}]

Regards,
Jean-Marc


  • Prev by Date: Re: Substitutions
  • Next by Date: Re: Riddle with Ordering
  • Previous by thread: Re: MatrixPlot: frame ticks starting with 0?
  • Next by thread: Riddle with Ordering