from Matlab vector to text file

Status
Not open for further replies.

english_style

Newbie level 3
Joined
Dec 6, 2010
Messages
3
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,296
Hi everybody,
I have to save a matlab vectror 1x256 in a text file.
I'm trying with save function, is this the right way?

thanks
 

I've discovered a good solution, so I post it 'cause maybe it could be usefull for someone else:
in Matlab Command Window:

fid=fopen('data.txt','wt');
fprintf(fid,'%d\n',I);
fclose(fid);

where fid is a temporary variable, data.txt the file we wanna get and I the vector 1x256.
bye
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…