MathGroup Archive 2012

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

Search the Archive

Re: List & Plot: do they parse options differently?


Unlike ListPlot, Plot has attribute HoldAll. Consequently, for Plot
you need to use Evaluate.

Attributes /@ {ListPlot, Plot}

{{Protected}, {HoldAll, Protected}}

Clear[s];
s = ImageSize -> Small;
ListPlot[{1, 2, 3}, s]
Plot[x, {x, 0, 3}, Evaluate[s]]


Bob Hanlon


On Fri, Sep 21, 2012 at 4:14 AM, James Stein <james at stein.org> wrote:
> I may have temporary blindness, but I fail to see why the call to Plot
> fails here:
>
> Clear [ s ] ;
> s = ImageSize -> Small;
> ListPlot [ {  1, 2, 3 } ,  s ]
> Plot [ x,  { x, 0, 3 } ,  s ]
>



  • Prev by Date: Re: creating a graphic in a text cell
  • Next by Date: Re: creating a graphic in a text cell
  • Previous by thread: Re: List & Plot: do they parse options differently?
  • Next by thread: Re: List & Plot: do they parse options differently?