RE: Graph inside another graph
- To: mathgroup at smc.vnet.net
- Subject: [mg68952] RE: [mg68922] Graph inside another graph
- From: "David Annetts" <davidannetts at aapt.net.au>
- Date: Fri, 25 Aug 2006 05:35:06 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
Hi Maruth,
> I am generating graphs in mathematica 5.0 that I export to
> eps for use in latex.
> I have two graphics objects each from MultipleListPlot[.],
> However I cannot seem to find a way to place a graph inside
> another graph (the inside graph being smaller and in an upper
> corner having it's own axis but within the frame of the
> larger graph). If anyone knows an easy method to do this, or
> any method at all I would appreciate it.
Use Rectangle[]. It's explained in the online documentation where there are
a few examples.
Here is another. First generate some data.
lst1 = Random[] & /@ Range[10];
lst2 = Random[] & /@ Range[10];
lst3 = Random[] & /@ Range[10];
Plot them
p1 = MultipleListPlot[lst1, lst2, PlotStyle -> {Red, Blue},
PlotRange -> {0, 1}];
p2 = MultipleListPlot[lst2, lst3, PlotStyle -> {Blue, Green},
PlotRange -> {0, 1}];
Display the second plot in the top right of the first.
p3 = Show[p1, Epilog -> {Rectangle[{6, .6}, {10.5, 1}, p2]}];
Regards,
Dave.