Re: Supressing Plot Output
- To: mathgroup at smc.vnet.net
- Subject: [mg16421] Re: Supressing Plot Output
- From: "hsn" <hsn at NOSPAM.ifa.au.dk>
- Date: Sat, 13 Mar 1999 02:21:38 -0500
- Organization: Hans & Humørgarden
- References: <7c59gj$7n3@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
Benjamin Rahn <brahn at fas.harvard.edu> skrev i artiklen <7c59gj$7n3 at smc.vnet.net>... > How can I overlay plots and graphics primitives _without_ displaying the > individual plots first? > > For example, I have a function that creates a plot of a spiral based > on three points in the plane: > > Spiral[A_,B_,C_]:=Module[ ... > ...; > ParametricPlot[...] ]; > > The function Spiral[] immediately generates the spiral, so the > command > > Show[Spiral[P,Q,R],Graphics[Line[{P,Q,R,P}]]]; > > gives two outputs: an image of the spiral by itself, and an image of the > spiral with the overlaid triangle. How can I restrict the output to the > second image? > > Thanks! > > -Ben > In your plotting commands use the option DisplayFunction->Identity, and then when it's time to show them use the option DisplayFunction->$DisplayFunction. e.g. p1=Plot[x^2,{x,-2,2},DisplayFunction->Identity] p2=Plot[x^3,{x,-2,2},DisplayFunction->Identity] Show[p1,p2,DisplayFunction->$DisplayFunction] Hans