MathGroup Archive 2006

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

Search the Archive

Re: Two independent y axes ?


Bill Rowe wrote:

> On 3/27/06 at 6:56 AM, spam at spam.invalid (Geico Caveman) wrote:
> 
>>I am trying to plot a bunch of functions and some data together.
>>Some of the data and some of the functions have *very* different y
>>range from the others. How do I create 2 independent y axes (like
>>gnuplot - y and y2 axes) to show the data effectively ?
> 
> Is something like the following what you are looking for
> 
> In[8]:=
> x = Sort[Table[Random[], {10}]];
> y = 20*Reverse[Sort[Table[Random[], {10}]]];
> 
> In[10]:=
> Show[Block[{$DisplayFunction = Identity},
>     {ListPlot[Rescale[x], PlotStyle -> Blue],
>      ListPlot[Rescale[y], PlotStyle -> Red]}],
>    Frame -> True, FrameTicks -> {Automatic,
>      Range[0, 1, 0.2], None, ({#1, 20*#1} & ) /@
>       Range[0, 1, 0.2]}];
> 
> --
> To reply via email subtract one hundred and four

No. I am plotting velocity and acceleration for a particle as a function of
time. These are physically distinct quantities and cannot share a y axis.
Having colorful legends will not cut it.


  • Prev by Date: Re: Problem with Thread over Plus?
  • Next by Date: Re: Problem with Thread over Plus?
  • Previous by thread: Re: Two independent y axes ?
  • Next by thread: Re: Two independent y axes ?