Re: GrahicsArray/Text
- To: mathgroup at smc.vnet.net
- Subject: [mg7919] Re: [mg7900] GrahicsArray/Text
- From: "Sherman.Reed" <sherman.reed at worldnet.att.net>
- Date: Mon, 21 Jul 1997 03:22:10 -0400
- Sender: owner-wri-mathgroup at wolfram.com
Deepak, Here is some code that works under both Mma 2.2.3 and 3.0. I plot something simple to work with: plt1=Plot[Sin[x],{x,-Pi,Pi}]; I then create some text to add to the plot; the coordinates determine the location, of course txt1=Text["Sin[x]",{2,-2}]; I then plot the text txx1=Show[Graphics[{txt1}]]; I then combine them in one graph. res1=Show[plt1,txx1]; I can now do the same with another graph and text set, say res2. Then I display the result in one graph: Show[GraphicsArray[{res1,res2}]] the above shows the graphs horizontally (side by side}, or. Show[GraphicsArray[{{res1},{res2}}]] the above shows the graphs vertically. The list construction of the arguement to GraphicsArray permits you to show matrices of graphs. Hope this helps Sherman C. Reed sherman.reed at worldnet.att.net ---------- > From: Deepak Kumar <dkumar at ringer.cs.utsa.edu> > Subject: [mg7900] GrahicsArray/Text > > Hi! > I'm trying to get Mathematica to display a few words of text in a > graphics array, like so: > > ______________________________________________________ > | | > | | > | | > | IMG 1 IMG 2 IMG 3 | > | | > | | > |'Frame 22' | > |___ ^ _______________________________________________| > | > > This is the text. > > > IMG 1, IMG 2 and IMG 3 are three images that are produced by this > command > Show[GraphicsArray[a, b, c]]; > > When I try and add this, > Show[GraphicsArray[a,b,c], Text["test", {0,0}]]; > > I get an error like so: > Show::gcc : Graphics of type *GrahicsArray* cannot be combined with > other types of graphics. > > I get the same error if I try using Text in the definition of a, b or > c. > > Any help would be greatly appreciated. > > Thank you, > > Deepak Kumar, > University of Texas, San Antonio. > > dkumar at ringer.cs.utsa.edu