Native plots are not attractive enough to put them into a document or a report.
You will find below some tricks to improve the graphic rendering of figures.
First, you will find a basic plot:
clf;//clear previous existing figures
//Plot the curves-------------------------------------------------------------
//The following 3 lines are enough to draw the curve itself.
//They are the minimum necessary.
x=[0:0.1:2*%pi]';
plot(x-4,sin(x), x+2,cos(x))
xgrid(2,1,7);//xgrid(color, thickness, style)
Now, let’s move on to the enhanced graphic:
// Various embellishments on a plot
//---------------------------------
clf;//clear previous existing figures
//Plot the curves-------------------------------------------------------------
//The following 3 lines are enough to draw the curve itself.
//They are the minimum necessary.
x=[0:0.1:2*%pi]';
plot(x-4,sin(x), x+2,cos(x))
xgrid(2,1,7);//xgrid(color, thickness, style)
//============================================================================
//All the lines that follow will enable you to embellish the graphic,
//personalize it, make it more readable,
//or even more attractive for incorporation into a document.
//Figure definition-----------------------------------------------------------
f=gcf();
f.background=color('gray50');// or any other predefined color name (in color_list)
f.figure_size=[1000,800];
f.figure_name='Post_tunig Axes and Curves';
//Axis definition-------------------------------------------------------------
a=gca(); // Handle on axes entity
a.x_location = "origin";// axis centered at (0,0)
a.y_location = "origin";// axis centered at (0,0)
a.thickness=2;
a.foreground=color('yellow');// color of the axis and box
a.background=color('gray80');// or any other predefined color name (in color_list)
//Customized axis label-------------------------------------------------------
//x axis
xstring(9.0,0.01,'time-->');
t1 = gce(); // get the handle of the newly created object
t1.font_foreground=7; // change font properties
t1.font_size=3;
t1.font_style=9;
//y axis
xstring(0.4,0.75,'curves-->',270);
t1 = gce(); // get the handle of the newly created object
t1.font_foreground=7; // change font properties
t1.font_size=3;
t1.font_style=9;
// Some additionnal improvements ...-------------------------------------------
isoview on
a.children // list the children of the axes :
//here we have a set of child composed of 2 entities : curve 1 and curve 2
//first curve
poly1= a.children.children(1); //store polyline handle into poly1
poly1.foreground = 2; // change the color...
poly1.thickness = 2; // ...and the thickness of a curve.
poly1.clip_state='off' // clipping control
//identifying the curve 1 on the plot
xstring(5,0.8,'curve 1')//identifying the curve 1 on the plot
t1 = gce(); // get the handle of the newly created object
t1.font_foreground=2; // change font properties
t1.font_size=3;
t1.font_style=9;
//second curve
poly2= a.children.children(2); //store polyline handle into poly2
poly2.foreground = 5; // change the color...
poly2.thickness = 4; // ...and the thickness of a curve.
poly2.clip_state='off' // clipping control
//identifying the curve 2 on the plot
xstring(-3.3,0.4,'curve 2')//identifying the curve 2 on the plot
t2 = gce(); // get the handle of the newly created object
t2.font_foreground=5; // change font properties
t2.font_size=3;
t2.font_style=9;
//Adding a plot legend---------------------------------------------------------
legend("sin(x)","cos(x)",4);
t3 = gce(); // get the handle of the newly created object
t3.font_foreground=1; // change font properties
t3.font_size=3;
t3.font_style=9;
//Adding a general title of the plot-------------------------------------------
title('my title','font_style',5,'color','green','edgecolor','yellow','backgroundcolor','peru','fontsize',5,'rotation',00,'position',[1.8 1]);
isoview off