Creating Distribution by Specifying Densities
조회 수: 1 (최근 30일)
이전 댓글 표시
Hi,
I would like to fit a distribution to a vector that contains the probability mass/densities of the desired distribution.
For example, assume my vector of probability masses is [0.02 0.1 0.015] with the corresponding x-coordinates being [-1 0 1.2].
(So I have a probability mass of 0.02 at x = -1, a probability mass of 0.1 at x = 0 and so on).
Is there any function in MATLAB that would allow me to fit say, a normal distribution to a distribution with the probability masses at the specified coordinates? I understand that options such as fitdist are available if I am dealing with a histogram/dataset but here I would like to fit a distribution given the probability masses/densities at certain points.
Any help would be much appreciated and thank you in advance.
댓글 수: 0
답변 (1개)
Torsten
2023년 4월 27일
편집: Torsten
2023년 4월 27일
If the masses add to 1, your x-coordinates together with the probability masses already define the distribution. There is no reason for fitting here.
If the masses don't add to 1, you can arbitrarily distribute (1-sum of masses) on the x-axis. So there is not senseful way of fitting and obtaining a distribution in this case.
댓글 수: 2
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!