Re: switching axes in Plot?
- To: mathgroup at smc.vnet.net
- Subject: [mg96340] Re: switching axes in Plot?
- From: dh <dh at metrohm.com>
- Date: Thu, 12 Feb 2009 06:33:23 -0500 (EST)
- References: <gmu8qa$glt$1@smc.vnet.net>
Hi John, the cheapest solution is simply to rotate the picture: Rotate[Plot[Sin[x], {x, 0, 10}], Pi/2] However, that is probably not good enough as the labels face the wrong way. A better way is to use ParametricPlot: ParametricPlot[{Sin[x], x}, {x, 0, 10}] hope this helps, Daniel John.Finnigan at csiro.au wrote: > When using Plot to plot F[x] as a function of x, Mathematica automatically = > assigns the independent variable x to the horizontal axis and the dependent= > variable F[x] to the horizontal. I often want to switch this around so th= > at the independent variable runs on the vertical axis and the dependent on = > the horizontal. I feel sure there ought to be a simple way to tell Plot to= > make this change but I have never found it and instead have resorted to co= > nvoluted approaches. Can anyone tell me what the simple trick is, if it ex= > ists? > Thanks > John Finnigan > >