フィルターのクリア

How to read specific columns of a Txt file and store them in an array?

3 ビュー (過去 30 日間)
MD MOSTAKIM ALAM SOHAG
MD MOSTAKIM ALAM SOHAG 2021 年 3 月 12 日
コメント済み: Star Strider 2021 年 3 月 14 日
I need to calcilate from coloum 4, initial data : row 1 coloum 4........... the from initial data i need to subtrct others data from coloum . then save the data . For better understnding. i have upload two photo. Please help me to solve this problem.

採用された回答

Star Strider
Star Strider 2021 年 3 月 12 日
Try this:
T1 = readtable('Data.txt','HeaderLines',1);
T1.Properties.VariableNames = {'t', 'vd', 'zd', 'mdro'};
T1.mdro = T1.mdro-T1.mdro(1);
and:
FirstFiveRows = T1(1:5,:)
produces:
FirstFiveRows =
t vd zd mdro
_____ _______ __________ ________
0 -10 0.00012 0
1e-07 -9.9908 0.000119 -3.7e-11
2e-07 -9.9704 0.000118 -5.4e-11
3e-07 -9.9576 0.00011701 -6.6e-11
4e-07 -9.924 0.00011601 -7.4e-11
.
  4 件のコメント
MD MOSTAKIM ALAM SOHAG
MD MOSTAKIM ALAM SOHAG 2021 年 3 月 14 日
Sure sir
Star Strider
Star Strider 2021 年 3 月 14 日
Thank you!

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeTables についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by