Hello,

I have a set of discrete value

X=[1 , 2, 10, 5, …., 4]

I want each value in X contains a probability value between 0 and 1

example:

1: 0.5,

2:0.1,

5:0.9

…..

Thanks.

Skip to content# MATLAB: How to generate probability value randomly

###### Related Question

MATLABprobability

Hello,

I have a set of discrete value

X=[1 , 2, 10, 5, …., 4]

I want each value in X contains a probability value between 0 and 1

example:

1: 0.5,

2:0.1,

5:0.9

…..

Thanks.

- Assigning probability
- Probability using binomial probability
- Picking random variables with different probablities
- Joint Probability
- How am I to generate random numbers with exponential distribution applied
- How can delete matrix randomly
- How to generate uniform discrete distribution starts from zero
- Probability distribution

## Best Answer