How do I use csvwrite in order to give me the data in a column and NOT in a single comma-separated line?

I want to create a txt file in which the numeric data will be in a column and not in a single comma-seperated row. I use csvwrite(out_file, Fz_norm); and it returnes all the numeric data in a single row

 Réponse acceptée

If the data is a column vector, it is printed as such
csvwrite('test.txt', (1:5)')
>> type test.txt
1
2
3
4
5

1 commentaire

the original data was a column vector. after I divided that with a number I want the algorithm to return a txt file in which the sata will have the original form which was like you described. But instead when I use csvwrite it returns me a text with the data in this form: 2,3,4,5

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by