Hello,

I have a matrix I got from another source that look like:

[0 5; 1 2; 2 1]

I wish to get a vector like [0 0 0 0 0 1 1 2] .

Thanks

EC

Skip to content# MATLAB: Creating a vector from a bin count

###### Related Question

vector

Hello,

I have a matrix I got from another source that look like:

[0 5; 1 2; 2 1]

I wish to get a vector like [0 0 0 0 0 1 1 2] .

Thanks

EC

- How to repeat columns in matrix in matlab R2014b
- How to augment a vector into another vector
- Block diagonal matrix of identity times scalar.
- How to use matrix elements as indices to access elements of another matrix
- How would you calculate the amount of 1 sets in a matrix
- Extracting the first contiguous values without looping
- How can i find deleted rows from matrix?

## Best Answer