use matlab code to draw the joint PMF and CDF
조회 수: 12 (최근 30일)
이전 댓글 표시
Hi, I am here confused about how to use 3D plot to draw the PMF (Probability Mass function) and CDF(Cumulative Distribution Function) based on x y two random variables. (The PMF I can draw it on paper but have no idea how to generate a code). Appreciate for the help
I tried the code below but it did not generate the graph what it supposed to be.
plot3([0 0 0],[0 0 0],[0 0 0.25])
hold on
plot3([1 0 0],[0 0 0],[0 0 0.125])
plot3(1, 0, 2)
hold on
plot3([0 0 0],[0 1 0],[0 0 0.5])
hold on
xlabel('X')
ylabel('Y')
zlabel('Probability')
grid on
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!