From 3d0c890de4ac7d9afd576e889bd2624437d79c70 Mon Sep 17 00:00:00 2001 From: Chayan Bhawal Date: Tue, 2 Oct 2018 10:19:33 +0530 Subject: Renamed_files_relative_path --- .../Scilab_code/Tutorial1_filehandling.sce | 25 ++++++++++++++++++++++ .../Scilab_code/Tutotial1_filehandling.sce | 23 -------------------- 2 files changed, 25 insertions(+), 23 deletions(-) create mode 100644 Tutorial01-Basics/Scilab_code/Tutorial1_filehandling.sce delete mode 100644 Tutorial01-Basics/Scilab_code/Tutotial1_filehandling.sce (limited to 'Tutorial01-Basics/Scilab_code') diff --git a/Tutorial01-Basics/Scilab_code/Tutorial1_filehandling.sce b/Tutorial01-Basics/Scilab_code/Tutorial1_filehandling.sce new file mode 100644 index 0000000..8942278 --- /dev/null +++ b/Tutorial01-Basics/Scilab_code/Tutorial1_filehandling.sce @@ -0,0 +1,25 @@ +//This function is to import data from a csv file and store it in a variable +//Using the data mean and standard deviation of the data is computed +clear +clc + +exec mymean.sci; +exec mystdev.sci; + +//Import data from csv file +Data = csvRead('../Data/Tut1_data1.csv'); +x = Data(:,1); +y = Data(:,2); + + +//Compute mean of the imported data +mean_of_x = mymean(x); +//Compute standard deviation of the imported data +stdev_of_x= mystdev(x,mean_of_x); + +//Data to be exported (It can be a scalar, vector or matrix) +data_to_write = [mean_of_x stdev_of_x]; +//Export data to a csv file +csvWrite(data_to_write,'../Data/Result.csv') + + diff --git a/Tutorial01-Basics/Scilab_code/Tutotial1_filehandling.sce b/Tutorial01-Basics/Scilab_code/Tutotial1_filehandling.sce deleted file mode 100644 index 2924f03..0000000 --- a/Tutorial01-Basics/Scilab_code/Tutotial1_filehandling.sce +++ /dev/null @@ -1,23 +0,0 @@ -//This function is to import data from a csv file and store it in a variable -//Using the data mean and standard deviation of the data is computed -clear -clc - -exec mymean.sci; -exec mystdev.sci; - -//Import data from csv file -Data = csvRead('../Data/Tut1_data1.csv'); -x = Data(:,1); -y = Data(:,2); - - -//Compute mean of the imported data -mean_of_x = mymean(x); -//Compute standard deviation of the imported data -stdev_of_x= mystdev(x,mean_of_x); - -//Data to be exported (It can be a scalar, vector or matrix) -data_to_write = [mean_of_x stdev_of_x]; -//Export data to a csv file -csvWrite(data_to_write,'../Data/Tut1_data3.csv') -- cgit