Mercurial > hg > octave-max
comparison scripts/plot/legend.m @ 8790:a013ff655ca4
Trivial changes to demos to produce a more pleasant output for octave+gnuplot+aquaterm.
author | Ben Abbott <bpabbott@mac.com> |
---|---|
date | Wed, 18 Feb 2009 00:46:24 -0500 |
parents | 5dd06f19e9be |
children | 485eabc0cfec |
comparison
equal
deleted
inserted
replaced
8789:d9bff42fec43 | 8790:a013ff655ca4 |
---|---|
226 endif | 226 endif |
227 | 227 |
228 endfunction | 228 endfunction |
229 | 229 |
230 %!demo | 230 %!demo |
231 %! close all; | 231 %! clf |
232 %! plot(1:10, 1:10, 1:10, fliplr(1:10)); | 232 %! plot(1:10, 1:10, 1:10, fliplr(1:10)); |
233 %! title("incline is blue and decline is green"); | 233 %! title("incline is blue and decline is green"); |
234 %! legend({"I'm blue", "I'm green"}, "location", "east") | 234 %! legend({"I'm blue", "I'm green"}, "location", "east") |
235 | 235 |
236 %!demo | 236 %!demo |
237 %! close all; | 237 %! clf |
238 %! plot(1:10, 1:10); | 238 %! plot(1:10, 1:10); |
239 %! title("a very long label can sometimes cause problems"); | 239 %! title("a very long label can sometimes cause problems"); |
240 %! legend({"hello world"}, "location", "northeastoutside") | 240 %! legend({"hello world"}, "location", "northeastoutside") |
241 | 241 |
242 %!demo | 242 %!demo |
243 %! close all; | 243 %! clf |
244 %! labels = {}; | 244 %! labels = {}; |
245 %! for i = 1:5 | 245 %! for i = 1:5 |
246 %! plot(1:100, i + rand(100,1)); hold on; | 246 %! plot(1:100, i + rand(100,1)); hold on; |
247 %! labels = {labels{:}, cstrcat("Signal ", num2str(i))}; | 247 %! labels = {labels{:}, cstrcat("Signal ", num2str(i))}; |
248 %! endfor; hold off; | 248 %! endfor; hold off; |