MathGroup Archive 2004

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: change PlotStyle in Graphics object after the fact?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg47285] Re: change PlotStyle in Graphics object after the fact?
  • From: bobhanlon at aol.com (Bob Hanlon)
  • Date: Fri, 2 Apr 2004 03:30:39 -0500 (EST)
  • References: <c4ggg8$3kb$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Needs["Graphics`Colors`"];

p1=Plot[x,{x, -1, 1},
      DisplayFunction->Identity];
p2=Plot[x^2,{x, -1, 2},
      DisplayFunction->Identity];

Show[{
      p1 /. 
        Graphics[{x__}, y__]->
          Graphics[{Blue, AbsoluteDashing[{5}], x}, y],
      p2 /. 
        Graphics[{x__}, y__]->
          Graphics[{Red, AbsoluteDashing[{10}], x}, y]}, 
    DisplayFunction->$DisplayFunction];


Bob Hanlon
In article <c4ggg8$3kb$1 at smc.vnet.net>, jflanigan at netzero.net (jose flanigan)
wrote:

<< I have a number of graphics objects created like

p1=Plot[f[x],{x,-1,1}]
p2=Plot[g[x], {x,-1,2}]

and I was wondering if I can change the PlotStyle on p1 and p2 by
doing something like

p2/.PlotStyle->{new plot style options}

Any ideas?


  • Prev by Date: Re: Expanding $Path
  • Next by Date: Re: Overflow --> Abort evaluation
  • Previous by thread: Re: change PlotStyle in Graphics object after the fact?
  • Next by thread: Re: change PlotStyle in Graphics object after the fact?