Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Electronic Equipment > Digital Signal Processing (DSP) > fprintf and str...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 2 Topic 13252 of 14332
Post > Topic >>

fprintf and string of characters

by raj <rajesh.obli@[EMAIL PROTECTED] > Jun 28, 2008 at 12:45 PM

Hai,

How to use newline for string of characters in fprintf?

outfile1 = fopen('samples_in.txt','w');

str = num2str( a.int );
fprintf( outfile1, '%s\n' ,str );
fclose(outfile1);

output:

it is writing into file as
1 23 34 34


but i want to write as
1
23
34
34

How can i achieve this?i searched in MATLAB do***entation and couldn't
find it?

pls suggest for this challenge..

regards,
raj
 




 2 Posts in Topic:
fprintf and string of characters
raj <rajesh.obli@[EMAI  2008-06-28 12:45:08 
Re: fprintf and string of characters
raj <rajesh.obli@[EMAI  2008-06-28 12:57:47 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Tue Dec 2 4:35:42 CST 2008.