how save diplayed data?
Mostrar comentarios más antiguos
hi,
i have the following code:
fid=fopen('webscopG.txt');
for j=1:100000
tline = fgetl(fid);
i=i+1;
if ~ischar(tline), break, end
disp(tline);
end
fclose(fid);
this code will display tline as array, and that what I need . But how I can save this array of tline.
thanks
2 comentarios
Image Analyst
el 6 de Abr. de 2012
Save it how? In a different text file? In a .mat file?
huda nawaf
el 12 de Abr. de 2012
Respuesta aceptada
Más respuestas (2)
Thijs
el 6 de Abr. de 2012
fid=fopen('webscopG.txt');
for j=1:100000
tline{i} = fgetl(fid);
i=i+1;
if ~ischar(tline),
break,
end
disp(tline);
end fclose(fid);
does that work?
1 comentario
Walter Roberson
el 6 de Abr. de 2012
No, you cannot have "fclose" in the same statement as "end".
Image Analyst
el 6 de Abr. de 2012
0 votos
Maybe open a second file for writing and write it out with fprintf()?
1 comentario
huda nawaf
el 12 de Abr. de 2012
Categorías
Más información sobre Audio and Video Data en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!