summaryrefslogtreecommitdiff
path: root/Tutorial2/Scilab_code/Tutorial2_semilog.sce
blob: 57cb3124467b1037bc4797ae9215e7a6c6a3ccb5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
//This script demonstrate multi-plotting in Scilab
clear 
clc

//Import data from file
Data = csvRead('/home/chayan/Documents/scilab-tutorials/Tutorial2/Data/Tut2_data1.csv');

//Segregate the data into variables
y = Data(:,1);
x = [Data(:,4) Data(:,5)]


//Figure 1 is a semilog plot
fig1 = figure();
plot2d(y,x,[1,2],logflag="nl")
legends(['Length of x1','Length of x3'],[1,2],opt="ur",font_size=1);


//Figure 2 is a loglog plot
fig2 = figure();
plot2d(y,x,[3,-1],logflag="ll")
legends(['Length of x1','Length of x3'],[3,-1],opt="ur",font_size=1);