how can Write matlab code for CDF and PDF

조회 수: 2 (최근 30일)
Muhammad Ali Qadar
Muhammad Ali Qadar 2013년 9월 11일
hi,
I want to write the code for pdf and cdf describe here http://snag.gy/9Fbt3.jpg please have a look Looking forward Thanks

채택된 답변

Muhammad Ali Qadar
Muhammad Ali Qadar 2013년 9월 16일
temp1=cumsum(cl)/sum(cl);
temp2=cumsum(cr)/sum(cr);
temp3=floor(256*temp1);
temp4=floor(256*temp2);
a=I;a2=a;
for i=0:255
if i<m1
a2(I==i)=m1*temp1(i+1);
else
a2(I==i)=m1+(max(I(:))-m1)*temp2(i+1);
end
end

추가 답변 (1개)

Shashank Prasanna
Shashank Prasanna 2013년 9월 11일
Can you provide more information? What random numbers are you working with?
Take a look at all the supported distributions. All the common PDF and CDFs are already available.
  댓글 수: 2
Muhammad Ali Qadar
Muhammad Ali Qadar 2013년 9월 11일
numbers you can use like 0:255, http://ieeexplore.ieee.org/xpls/abs_all.jsp?arnumber=580378 is the paper that I am trying to implement but I am sure I am not coding very well, and I think Matlab built in Distribution may not applicable, Infact I Also dont Want to Use MAtlab built-in to build understanding of equations and how to code them, Sorry I am newbie.
Muhammad Ali Qadar
Muhammad Ali Qadar 2013년 9월 11일
please let me know if you can not download the paper

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

Community Treasure Hunt

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

Start Hunting!

Translated by