www.gusucode.com > graphics 案例源码程序 matlab代码 > graphics/DeleteLegendExample.m

    %% Delete Legend
% Create a chart with a legend. Then, delete the legend. 

plot(rand(3))
legend('line 1','line 2','line 3')

%%
legend('off')