Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Need advice on File I/O
Date: Sat, 1 Sep 2007 00:02:26 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 24
Message-ID: <fbaa6i$3pu$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1188604946 3902 172.30.248.37 (1 Sep 2007 00:02:26 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Sat, 1 Sep 2007 00:02:26 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1030060
Xref: news.mathworks.com comp.soft-sys.matlab:426541



I am working with delimited text files (mostly, but not
always, comma separated or CSV).

Reading and creating entire files isn't a problem. My
problems start when I need to alter data in existing files.
I could use some advice.

Sometimes I will need to remove an entire line from a file.
Sometimes I need to replace a single value (at any row,
column location) without changing the rest of the file.

After searching and reading everything I can find in the
help, I am still undecided on how to go about this. I would
appreciate some advice from experienced Matlab users.

I simply can't see an easy way to modify my file data with
the Matlab file I/O functions I see listed in help. 

(I'm working on Windows and my data is all ASCII. The
delimiters and data organization in the files is not always
uniform, so I often have to write code to analyze each
character I read from a file and figure out where the data
is that I want to change. However, I don't think there is
anything really unusual about what I need to do.)