Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
Drexel University or The Math Forum.


GIRAY
Posts:
11
Registered:
1/16/10


Re: Automating Copy/Paste with MATLAB
Posted:
Aug 7, 2013 2:57 PM


The issue with my data file is that it contains a header block with useless information for about 10 rows, then the delimited data comes. So using dlmread is fails, because the data itself cannot be acquired by dlmread.
"someone" wrote in message <ktu40r$g9p$1@newscl01ah.mathworks.com>... > "GIRAY" wrote in message <ktu28p$b3u$1@newscl01ah.mathworks.com>... > > Howdy Folks, > > > > I like to work with Excel workbooks when I am processing long data files, because xlsread function nicely organizes rawdata, textdata and numeric data into variables. > > > > I am, however, unable to process long files with excel due to memory errors and the limit of rows excel dictates. > > > > Let's forget about the limit of usable rows with excel for now, and assume that I have 200 rows of data on a .dat (or .txt) format which needs to be processed. > > > > I have created algorithms to use with xlsread function that I don't want to rewrite for dlmread or textread functions. I want Matlab to automatically read in that txt or dat file and paste it into a excel file, so essentially, the question is, how can I convert a text file to an excel workbook automatically under Matlab? I want to avoid that primitive copy/paste method that I do by hand by utilizing Matlab. > > > > How can I approach this problem? > > > > Thanks. > > Maybe I'm missing something, but it seems to me that a two line mfile should do the trick. Something like: > > function CreateXLS(filenameIn,fileNameOut) > M = dlmread(filenameIn); % include options you need > xlswrite(filenameOut,M)



