[Scilab-users] finding similar values with scilab

Paul CARRICO paul.carrico at free.fr
Sat Feb 22 09:04:28 CET 2014


I've ever suggested to use "awk" / "sed" and other linux tool (even under Windows) in conjunction to Scilab ;

1rst step : concatenate all the files if necessary (with Scilab for example)

Average :
http://azimuth.biz/2009/03/30/calculate-average-using-awk/

standard deviation :
http://azimuth.biz/2010/02/25/calculate-standard-deviation-using-awk/


Min-Max:
http://azimuth.biz/2010/10/20/find-minimum-and-maximum-using-awk/


supress values greater than : (ditto for min value)
http://www.unix.com/shell-programming-scripting/178904-awk-show-lines-where-nth-column-greater-than-some-number.html
http://oreilly.com/catalog/unixnut3/chapter/ch11.html


and so on

I'm not a awk/sed specialist, but I've a look to such tools when my input files have million's of lines ... and it works fine and fast !!!
Just an idea


NB: tutos
http://www.grymoire.com/Unix/Awk.html
http://www.cs.unibo.it/~renzo/doc/awk/nawkA4.pdf
etc. ...




-----Message d'origine-----
De : users [mailto:users-bounces at lists.scilab.org] De la part de Paul CARRICO
Envoyé : samedi 22 février 2014 08:48
À : 'International users mailing list for Scilab.'
Objet : Re: [Scilab-users] finding similar values with scilab

Do you have to do this on a single file and to repeat it X times (where X is the thousands of file you're speaking) or do you have to calculate the deviation and so on) on the X files at the same time ?

Obviously the first case is much easier than the second one .....



-----Message d'origine-----
De : users [mailto:users-bounces at lists.scilab.org] De la part de samaelkreutz Envoyé : samedi 22 février 2014 00:26 À : users at lists.scilab.org Objet : Re: [Scilab-users] finding similar values with scilab

I need compute an iteration , but (obviously I don't know how to do it  =/  ) Read thousand of text files... then what I do is check the mean, stand.
deviation, and variation coefficient ( std/mean ). If the variation coefficient is <= 0.4, stop the process. If not, eliminate the big value and recalculate all the process again.

But i'm lost!!! because Im reading multiple text files and is confusing!!!!! 
Heeelp!!!!  




clc
clear all
z=[]; // genero mi matriz vacia que se ira llenando con el for  for i=103 //35:2:37// 
     for j=2.6:0.1:3.9//
     DM = fscanfMat(msprintf("new-C1_%d_%3.1f.txt",i,j));
     //disp(i,j)
     med=mean(DM(:,3));
     std=st_deviation(DM(:,3));
     CV=std/abs(med);
     Z=[med std CV CV*100];
     z=[z;Z]; // Matriz con información requerida
     //figure(i);
     //plot(DM(:,1), DM(:,3), 'ro*') 
     end
 end
z




--
View this message in context: http://mailinglists.scilab.org/finding-similar-values-with-scilab-tp4028792p4028865.html
Sent from the Scilab users - Mailing Lists Archives mailing list archive at Nabble.com.
_______________________________________________
users mailing list
users at lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users


---
Ce courrier électronique ne contient aucun virus ou logiciel malveillant parce que la protection avast! Antivirus est active.
http://www.avast.com

_______________________________________________
users mailing list
users at lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users


---
Ce courrier électronique ne contient aucun virus ou logiciel malveillant parce que la protection avast! Antivirus est active.
http://www.avast.com




More information about the users mailing list