Filling

Filling
is an option for ListPlot, Plot, Plot3D, and related functions that specifies what filling to add under points, curves, and surfaces.

DetailsDetails

  • The following settings can be used:
  • Noneno filling (default)
    Axisfill to the axis
    Bottomfill to the bottom of the plot
    Topfill to the top of the plot
    vfill to value v
    {m}fill to the m^(th) object
    {i1->p1,i2->p2,}fill from object ik to pk
    {i1->{p1,g1},}use directive gk for the k^(th) filling
    {i1->{p1,{g1-,g1+},}}use g1- below and g1+ above
  • For 2D graphics, filling is done in the y direction.
  • For 3D graphics, filling is done in the z direction, and on the bounding xy plane.
  • In ListPlot, filling effectively draws a "stem" to every point.
  • For multiple curves, surfaces or lists of points, Filling->p is equivalent to Filling->{1->p,2->p}.
  • In filling between lists of points that do not line up, the "stems" start at points in the first list, and extend to positions that linearly interpolate between points in the second list. »
  • By default, the style specified by the setting for FillingStyle is used for all filling.
  • Settings of the form ik->{pk,gk} can be used to override the default in particular cases.
  • ik->{pk,{gk -,gk +}} specifies that style gk - should be used when ik lies below pk, and gk + when it lies above.
  • The gk - and gk + can be composite directives specified with Directive.

ExamplesExamplesopen allclose all

Basic Examples  (4)Basic Examples  (4)

Fill to different levels:

In[1]:=
Click for copyable input
Out[1]=

Fill multiple curves:

In[1]:=
Click for copyable input
Out[1]=

Fill for a point-oriented plot:

In[1]:=
Click for copyable input
Out[1]=

Fill for a surface-oriented plot:

In[1]:=
Click for copyable input
Out[1]=
Introduced in 2007
(6.0)
Translate this page: