diff options
Diffstat (limited to 'Tutorial2_Plot/Scilab_code/Tutotial2_plot_save.sce')
-rw-r--r-- | Tutorial2_Plot/Scilab_code/Tutotial2_plot_save.sce | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/Tutorial2_Plot/Scilab_code/Tutotial2_plot_save.sce b/Tutorial2_Plot/Scilab_code/Tutotial2_plot_save.sce index 20a8427..a3da8f3 100644 --- a/Tutorial2_Plot/Scilab_code/Tutotial2_plot_save.sce +++ b/Tutorial2_Plot/Scilab_code/Tutotial2_plot_save.sce @@ -6,13 +6,24 @@ clc Data = csvRead('/home/chayan/Documents/scilab-tutorials/Tutorial2_Plot/Data/Tut2_data1.csv'); //Segregate the data into variables -y = Data(:,1); -x1 = Data(:,2) +t = Data(:,1); +x = Data(:,2) -//Figure 1 is y versus x1 with linewidth = 3 -//fig1 = figure(); +//Ploting the figure. Name of the figure is fig1; +//Use the field Linewidth to specify thickness of the plot fig1 = scf(1); -plot(y,x1,'Linewidth',3); +plot(t,x,'Linewidth',3); + +//Adding title, xlabels and ylabels +//Changing thickness and textsize in plot +attrib_axes = gca(); //Attributes of axes of active handle +attrib_axes.x_label.text = 'Time'; //X-label +attrib_axes.y_label.text = 'Data'; //Y-label +attrib_axes.title.text = 'x versus t'; //Title of the plot +attrib_axes.x_label.font_size = 5; //X_label font size +attrib_axes.y_label.font_size = 5; //Y_label font size +attrib_axes.title.font_size = 5; //Title font size +attrib_axes.font_size = 4; //Font size of x-axis and y-axis //Export Figure 1 as svg file xs2svg(fig1,'plot_y_versus_x1'); |