Merging multiple files into one single file by MATLAB

2 ビュー (過去 30 日間)
mmenvo
mmenvo 2012 年 4 月 2 日
Here i am sharing one of my data which are in .dat file. I have 16162 different files. I merged all into one file and want to read it in matlab and need to extract three parameter's values from a single file and arrange them in either row wise or column wise. I can do it by using C sharp codes but i want to do it by using matlab. can anybody help me out for writing the codes please?
Here is the one sample file data:
DISTRIBUTION: monomodal log-normal
n : 1.000
r_mod: .010
sigma: 1.400
number conc., surface. conc., volume conc.
.1087E+01 .1866E-02 .7878E-05
part. ave. radius, surf. ave. radius, vol. ave. radius :
.1149E-01 .1169E-01 .1201E-01
surface mean radius, volume mean radius :
.1267E-01 .1392E-01
eff. variance :
.9939E-01
Let's say: I want to extract or read three parameters (r_mod, sigma, Surface means radius). The corresponding values for these three parameters from the file I put in this page is .010 , 1.400 , .1267E-01
The output should be (Which i want):
r_mod sigma surface mean radius
.01 1.4 1.27E-02
.02 1.4 2.67E-02
.03 1.4 3.98E-02
... .. .. ..
.. .. .. ..
I have more than thousands similar files in a same directory. I want to read all those files in matlab and the output should show in this way in a single file.
  2 件のコメント
dhamini pasam
dhamini pasam 2016 年 1 月 12 日
hi did u get the solution for the question which u have asked.if you have the solution please let me know i too have same problem
Mohamed O.M. Khelifa
Mohamed O.M. Khelifa 2016 年 9 月 30 日
Hi, we have the same problem, thank for sharing the solution if you get it

サインインしてコメントする。

回答 (1 件)

Walter Roberson
Walter Roberson 2012 年 4 月 2 日

カテゴリ

Help Center および File ExchangeData Import and Analysis についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by