How to extract data from a specified row number (omitting first row)
9 views (last 30 days)
I have a cell array from which I want to extract data from the rows between parts highlighted yellow in the image below (just part of the array shown).
I want to first indicate the start and end of these rows, as following:
%% find the kewords for start and end
idx_rtoe_start = find(strcmp(data_raw(:, 2), '"Right Toe"'));
idx_rtoe_end = find(strcmp(data_raw(:, 2), '"HX210.11.31.M7-LF S0021"'));
%% indices between idx_rtoe_start and idx_rtoe_end
idx = arrayfun(@(idxStart, idxEnd) idxStart:idxEnd, idx_rtoe_start, idx_rtoe_end,...
However, '"HX210.11.31.M7-LF S0021"' occurs for the first time earlier in the file (before 'righ toe') and the code above (bolded part) gives the the first location it occurs. I want this to start from the second time it occurs. I cannot use another keyword as these also occur earlier in the file.