publish function taking long time on this program??this is a program to generate histogram of an image. earlier I have written the program as a function and then changed it to a normal program.When I try to publish this code...it's taking a long time

2 views (last 30 days)
% clc
close all
clear all
v=imread('bb.jpg');
N=size(v);
for i=0:256;
count=0;
for r=1:N(1);
for c=1:N(2);
if v(r,c)==i;
count=count+1;
end
end
end
op(i+1)=count;
end
figure
imshow(v);
title('image')
figure
stem(op);
title('image histogram')

Answers (0)

Community Treasure Hunt

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

Start Hunting!