title

Purpose

Graph title.

Synopsis

title('text')

Description

title('text') writes the text as a title at the top of the current plot.

Examples

The statement

title(date)
puts today's date on the top of the current plot.

Two examples of including a variable's value in a title are

f = 70; c = (f-32)/1.8;
title(['Temperature is ',num2str(c),' degrees C'])
          
n = 3
title(['Case number #',int2str(n)])

Algorithm

title sets the Title property of the current axes object to a new text object.

See Also

gtext, int2str, num2str, plot, text, xlabel, ylabel, zlabel

(c) Copyright 1994 by The MathWorks, Inc.