This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

Footer, Header

Value Summary

Footer, HeaderOptionalText string

Graphics Primitives

ObjectsDefault Values
plot::Canvas, plot::Scene2d, plot::Scene3d 


Footer = "…" sets a text to be displayed at the bottom of a scene or canvas.

Header = "…" sets a text to be displayed at the top of a scene or canvas.

As described in the introduction, each plot consists of a canvas containing one or more scenes. Using Header and Footer, you can set captions for both levels of nesting, above and/or below the contents.

To change the appearance of the captions, please use the attributes FooterAlignment and HeaderAlignment for positioning and FooterFont and HeaderFont to control fonts and sizes.


Example 1

The easiest way of setting a caption is to include a canvas-caption in a plot command:

plot(plot::Function2d(sin(x), x = 0..2*PI),
     Footer = "the sine function"):

You can also set style controlling attributes in this context:

plot(plot::Function2d(sin(x), x = 0..2*PI),
     Header = "the sine function",
     HeaderFont = ["Monotype Corsiva", 17, RGB::Red],
     HeaderAlignment = Left):

Example 2

Advanced users may want to plot several scenes together. These can be given individual captions:

f1 := plot::Function3d(sin(x^2 + y^2)*(x^2 + y^2),
                       x = -3..3, y = -3 ..3,
                       AdaptiveMesh = 0):
f2 := plot::modify(f1, AdaptiveMesh = 2):
s1 := plot::Scene3d(f1, Footer = "AdaptiveMesh = 0"):
s2 := plot::Scene3d(f2, Footer = "AdaptiveMesh = 2"):
plot(s1, s2, Layout = Horizontal)

Was this topic helpful?