AW: Reverse Axis

• To: mathgroup at smc.vnet.net
• Subject: [mg23610] AW: [mg23559] Reverse Axis
• From: Wolf Hartmut <hwolf at debis.com>
• Date: Wed, 24 May 2000 02:16:10 -0400 (EDT)
• Sender: owner-wri-mathgroup at wolfram.com

```
-----Ursprüngliche Nachricht-----
Von:	Carl Liggio [SMTP:cliggio at flashcom.net]
Gesendet am:	Samstag, 20. Mai 2000 09:11
An:	mathgroup at smc.vnet.net
Betreff:	[mg23559] Reverse Axis

Is there a way to reverse the axis on a 2-D plot?

I am trying to flip the negative and the positive.

Dear Carl,

perhaps you may try out the following:

You may have plots

p = Plot[BesselJ[0, x], {x, 0, 6 Pi}]

p2 = Plot[BesselJ[1, x], {x, 0, 4 Pi}, PlotStyle -> Hue[0]]

Define

ShowReflected[plots__, op_] :=
With[{g0 = FullGraphics[First[Flatten[{plots}]]],
grest = Graphics /@ Rest[Flatten[{plots}]]},
Show[{g0, grest} /. {Line[pts_] :> Line[op # & /@ pts],
Text[t_, coord_, offset_] :> Text[t, op coord, op
offset]},
PlotRegion -> {{0.05, 0.95}, {0, 1}}]]

and try

ShowReflected[p, p2, {-1, 1}]

ShowReflected[p, p2, {1, -1}]

ShowReflected[p, p2, {-1, -1}]

(perhaps some time you need to tamper with PlotRegion)

Kind regards,  Hartmut

```

• Prev by Date: Re: Linking with C++
• Next by Date: Re: hung for good?
• Previous by thread: Pb with ZeroTest
• Next by thread: Re: , sending notebook attatchments, -- a partial solution...