[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: dlmwrite

From: Susanne Nieß
Subject: Re: dlmwrite
Date: Mon, 27 Jun 2011 15:41:42 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; de; rv: Gecko/20110616 Thunderbird/3.1.11

Thank you for your advice. Now I have an even simpler example:

q=[1 2 3; 4 5 6];
dlmwrite('testcsv',q,'delimiter',' ','precision',20);

1g 2g 3g
4g 5g 6g

If I use the command "save" this changes the format, I want it as a csv to leave it compatible with something else. Up to now, I tried to read files with "load". Even if I can read those files with dlmread, the additional "g" after each number will cost a lot of disk space so the best thing would still be to eliminate it. There was something about this on the bug tracker under bug #29870 but I could not use the solution because the mentioned file does not exist on my system. Can you help my?

Am 26.06.2011 15:46, schrieb Carnë Draug:
2011/6/25 Susanne Nieß<address@hidden>:

I have a problem with dlmwrite.
The code attached in bam.m  works fine on matlab producing a normal
file. In octave, however, it produced the file qjbx0203 that I also
with a "g" following every number. Octave itself is not able to read this
crazy file. This is a real problem for me because I need such files and
only limited possibilities to make them on matlab. Could you please help

I believe you forgot to attach the file. Try using
instead of attaching files.

On 26 June 2011 13:23, Susanne Nieß<address@hidden>  wrote:
Sorry. Here it is:

q=[q1 q2 q3];
dlmwrite('qjbx0203',q,'delimiter',' ','precision',20);

1g 1g 6g
2g 2g 2g
3g 2g 2g
4g 3g 2g

You forgot to also reply to the mailing-list. It's better to keep
conversations there so that everyone can help. Also, you didn't attach
the files with the original matrix (qjbx1203 and qjbx013).

Anyway, I can read the file generated with dlmwrite, no problem, with
dlmread. Try:


You could use the command 'save' to save the matrix into a file as well.

Carnë Draug

reply via email to

[Prev in Thread] Current Thread [Next in Thread]