Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2007
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2007

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

Search the Archive

Re: Help in changing the vertical axis tick label format

  • To: mathgroup at smc.vnet.net
  • Subject: [mg76326] Re: [mg76269] Help in changing the vertical axis tick label format
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Sat, 19 May 2007 04:53:30 -0400 (EDT)
  • Reply-to: hanlonr at cox.net

f[x_] := 25500 + 230 * x;

plt=Plot[  f[x], {x, 2000, 2007}, PlotRange -> {485000, 487000}  ,
      DisplayFunction->Identity];

yTcks=(Ticks/.AbsoluteOptions[plt,Ticks])[[2]]/.
      {y_?NumericQ,yLabel_?NumericQ,r__}:>
        {y,ScientificForm[yLabel,{5,4},NumberPadding->{"","0"}],r};

Show[plt,Ticks->{Automatic,yTcks},DisplayFunction->$DisplayFunction];


Bob Hanlon

---- siewsk at bp.com wrote: 
> Everyone,
> 
>   I have a problem with the simple 2D plotting on mathematica 5.2
> 
> Here is a simple 2D plot
> 
> f[x_] := 25500 + 230 * x;
> 
> Plot[  f[x], {x, 2000, 2007}, PlotRange -> {485000, 487000}  ]
> 
>   My problem is that the vertical axis tick label are
> 
> 485250
> 485500
> 485750
> 486000
> 486250
> 486500
> 486750
> 487000
> 
>   What I wanted is the vertical axis label in scientific format of
> 
> 4.8525*10^5
> 4.8550*10^5
> 4.8575*10^5
> 4.8600*10^5
> 4.8625*10^5
> 4.8650*10^5
> 4.8675*10^5
> 4.8700*10^5
> 
>   And I do not have a clue on how to force it to be in the scientific
> format.
> 
>   Thanks for your help in advance.
> 
> 



  • Prev by Date: Re: Using N function
  • Next by Date: Re: v.6 Editing Stylesheets
  • Previous by thread: Help in changing the vertical axis tick label format
  • Next by thread: Re: Help in changing the vertical axis tick label format