<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#330000">
hi<br>
<br>
did you try write_csv(Matrice,"max.txt") ?<br>
<br>
<br>
On 11/08/2011 16:10, boutardd wrote:
<blockquote cite="mid:1313071817692-3246029.post@n3.nabble.com"
type="cite">
<pre wrap="">Hi,
I got some files called Full_abcde1.txt, Full_abcde2.txt,.....to read.
The *.txt files is a matrix of double element like [1, 2,3, 4]
I would like to be able to create a matrix or something similar in which the
first column is a part of the name of the files "abcde1" and the second
column is the 3rd row in my files (=3).
My problem is that I do not know the format (matrix or other) to save string
and double in the same object. So I convert double to string and get a
matrix of string but I did not find the right function save or right syntax
to record data into .txt file. I copy my file if someone got a solution for
me :)
Thanks in advanced
David
My file is :
a=length('full_')
FichTxt=uigetfile(["*.txt"],"","Fichier texte",%t)
NbFiles=size(FichTxt,2)
for i = 1:NbFiles
temp1=fscanfMat(FichTxt(i))
pos(i,1)=strindex(FichTxt(i), 'full_')
pos(i,2)=strindex(FichTxt(i), '.txt')
index(i)=part(FichTxt(i),(pos(i,1)+a):pos(i,2))
Matrice(i,1)=index(i)
Matrice(i,2)=string(temp1(1,3))
Matrice(:,:) // Allow me to see what is int the matrix
end
//My problem start now because I do not know function to save "Matrice", I
have tried savematfile, fprintfmat or save but nothing work or I have not
got the right syntax.
save('max.txt',Matrice)
--
View this message in context: <a class="moz-txt-link-freetext" href="http://mailinglists.scilab.org/Save-a-matrix-of-string-tp3246029p3246029.html">http://mailinglists.scilab.org/Save-a-matrix-of-string-tp3246029p3246029.html</a>
Sent from the Scilab users - Mailing Lists Archives mailing list archive at Nabble.com.
</pre>
</blockquote>
<br>
<br>
<div class="moz-signature">-- <br>
<p style="color:teal; font-size:12pt;"><b>Adrien Vogt-Schilb</b><br>
Research Fellow<br>
<a class="moz-txt-link-abbreviated" href="mailto:vogt@centre-cired.fr">vogt@centre-cired.fr</a><br>
Tel: (+33) 1 43 94 73 96<br>
Fax: (+33) 1 43 94 73 70<br>
</p>
<table style="border:none;">
<tbody>
<tr>
<td style="padding:0pt 0pt 0pt 0pt;">
<p><img src="cid:part1.00050809.00050808@centre-cired.fr"
alt="CIRED" width="54"></p>
</td>
<td style="padding:0pt 7pt 0pt 7pt;" valign="middle">
<p style="font-size:10pt; color:teal">45 bis, Av de la
Belle Gabrielle<br>
F-94736 Nogent-sur-Marne<br>
<a href="http://www.centre-cired.fr/" style="color:teal">http://www.centre-cired.fr/</a><br>
</p>
</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>