How do I use the values in a .txt file to create a stacked bar graph?
2 次查看(过去 30 天)
显示 更早的评论
I've already been successful at opening the file and obtaining the values
fileID = fopen('report_data.txt','r');
patientName=fgetl(fileID);
dateOfBirth=fgetl(fileID);
notes=fgetl(fileID);
healthy_exposed = fgetl(fileID);
pus = fgetl(fileID);
necrotic = fgetl(fileID);
ulcer_stage = fgetl(fileID);
area = fgetl(fileID);
volume = fgetl(fileID);
fclose(fileID);
But I'd like to take healthy_exposed, pus, and necrotic and create a stacked bar graph.
0 个评论
回答(1 个)
Dishant Arora
2014-3-26
编辑:Dishant Arora
2014-3-27
bar( [str2num(healthy_exposed)', str2num(pus)', str2num(necrotic)'], 'stacked')
4 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Graphics Object Programming 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!