Creating a table from outputs

7 ビュー (過去 30 日間)
Katherine Medina
Katherine Medina 2020 年 1 月 8 日
編集済み: Ganesh Regoti 2020 年 1 月 17 日
I've been trying to create a table to display results neatly. The purpose of the code is to match patient between two spreadsheets based on Age & BMI. Then to take those matches and display them in a table.
Match=zeros(46,10);
Found=zeros(50);
for y=1:length(En.SubNumE)
if ismember(Pen.AgeP(Target),En.AgeE(y)+(-2:2)) && ismember(Pen.BMIP(Target),En.BMIE(y)+(-2:0.1:2))
Match(y) = 1;
Found(j) = En.SubNumE(y);
j=j+1;
end
end
I'm not sure how to proceed. I successfully had a table when the data set was much smaller (10 vs 50). I want to display the Subject Number, Last Name, Age, and BMI for the matched people.

回答 (1 件)

Ganesh Regoti
Ganesh Regoti 2020 年 1 月 17 日
編集済み: Ganesh Regoti 2020 年 1 月 17 日
Hi,
I understand that you want to compare data from spreadsheets with small tolerance and display the output as tables.
Steps:
  1. Convert the spread sheet data into table format.
2. You can use ismembertol function to check the data between two tables.
Hope this helps!

カテゴリ

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

製品


リリース

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by