hello i am working on a project in matlab for the reflectivity measurement...can any body help me ?
1 次查看(过去 30 天)
显示 更早的评论
i have a code for generating area plot of multiple images but it takes all the plots in a loop and after loop it takes only the last plot..i want area of each plot to be save in a variable and make an array of these variables...here is my code.
for i=1:7;
for j=-3:3;
file_name=strcat('C:\Users\ASUS\Desktop\imgs\c',num2str(i),'.gif');
im=imread(file_name);
[centers, radii]=imfindcircles(im,[10 20]);
center=centers(1,2);
c=round(center);
area(im(c+j,:));hold all;
end
end
but this gives all area in a single figure..i need to plot area of particular image within that range in a figure and save it for further calculation....any idea for this..?
回答(2 个)
Shaik Pasha
2015-3-31
area_calc=[]; for i=1:7 for j=-3:3 file_name=strcat('C:\Users\ASUS\Desktop\imgs\c',num2str(i),'.gif'); im=imread(file_name); [centers, radii]=imfindcircles(im,[10 20]); center=centers(1,2); c=round(center); area_calc(i)=area_calc(i) + area(im(c+j,:)); hold all; end end
Hi check with this. As per my understanding this must help you out. If my understanding is incorrect please let me know the correct one.
Image Analyst
2015-3-31
"i just want to calculate area of particular spot", so see my Image Segmentation Tutorial: http://www.mathworks.com/matlabcentral/fileexchange/?term=authorid%3A31862
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!