필터 지우기
필터 지우기

Plotting histogram in Matlab Gui

조회 수: 2 (최근 30일)
Jonasz
Jonasz 2013년 8월 19일
I try to plot a histogram in Matlab Gui using axis control. But nothing change after running code below:
Code:
handles.hist=hist(sort(averSpectrum),500);
guidata(hObject, handles);
What is wrong I have tried almost every combination.

채택된 답변

Image Analyst
Image Analyst 2013년 8월 19일
[counts, binCenters] = hist(sort(averSpectrum),500);
axes(handles.whateverAxesYouWant);
bar(binCenters, counts, 'BarWidth', 1);
grid on;
  댓글 수: 3
Image Analyst
Image Analyst 2013년 8월 19일
Double click the axes where you want to display the histogram to bring up the property inspector. Then look at the "tag" property. What does it say? Is the value of the tag property "hist" or is it some other word?
Jonasz
Jonasz 2013년 8월 19일
I find what happen. It's the same name of variable and tag. Sorry for bothering you but it wasn't so obvious for me

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Migrate GUIDE Apps에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by