help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Increasing font size of legend


From: Bob Odom
Subject: Re: Increasing font size of legend
Date: Thu, 30 Dec 2010 20:09:26 -0800 (PST)
User-agent: Alpine 2.00 (DEB 1167 2008-08-23)


On Fri, 31 Dec 2010, asha g wrote:

 

Does this do any good?

legend(leg,'location','southeast');
set (gca,'fontsize',20)


No. It says leg undefined in line 148.


_______________________________________________
Help-octave mailing list
address@hidden
https://mailman.cae.wisc.edu/listinfo/help-octave

Asha,

I think the line should look like:

legend('Airy(x)',"location",'southeast');

where you should substitute whatever you have for "leg" for Airy(x), i.e. leg
is the text of your legend.

Do: 'help legend' at the octave prompt.

I have also noticed in the forum that there are problems controlling the
legend font size, which may have been solved in the developer sources, but
not in the stable releases (3.2.4).

If all you need is a text label of some kind without the line type or
color, you can use the 'text' function. For example, I have the two lines:

set (0,"Defaulttextfontsize", '26');
text (1600, 1.5, "5 layers",'color', b);

My x-range is 1500 -> 1700, and y-range is 0 -> 10. The 'text' call above
puts the message (5 layers) in the figure starting at the location
(1600,1.5) in blue and with a font size of 26 points.

There is a lot of information on setting plot parameters in the forum
archives. It is worth a look.

Bob

reply via email to

[Prev in Thread] Current Thread [Next in Thread]