Importing alternating data points

조회 수: 9 (최근 30일)
James Towell
James Towell 2018년 12월 9일
답변: Akira Agata 2018년 12월 10일
Im trying to import every 100th value from a txt file with 4 lines of header from the 4th column within that file.
Appreciate any help.
  댓글 수: 2
madhan ravi
madhan ravi 2018년 12월 9일
upload the text file
James Towell
James Towell 2018년 12월 9일
There you go

댓글을 달려면 로그인하십시오.

답변 (1개)

Akira Agata
Akira Agata 2018년 12월 10일
Like this? Using this code, you can extract every 100th value (100th, 200th,...etc) from the 4th column.
T = readtable('Dataset1_1.txt','HeaderLines',4,'ReadVariableNames',false);
data = T{100:100:end,4};

카테고리

Help CenterFile Exchange에서 Data Import and Analysis에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by