hi every body how can I represent the histogram of a data vector without using the hist function ? thanks
No products are associated with this question.
no what i mean that i dont want to represent it with bars but only line that represent the distribution of my data(in vector)
You would essentially have to program up the internals of the histogram function yourself. Very, very easy to do, once you've decided on your bin edge locations. Just think it through in your head and I'm sure you'll know what the code needs to be. It's fairly trivial, so you probably won't need any help.
X = randi(20,40,1); ii = [-inf 0:4:20 inf] out = sum(bsxfun(@lt,X,ii(2:end))&bsxfun(@ge,X,ii(1:end-1))) histc(X,ii)
THANKS andrei Bobrov for the response but i need not to use the histc function because i want to represent my data without bars only line