I have a matrix composed of ones and zeros.
I need to idenity where there are three 1s in each COLUMN
1 0 0 1 11 0 1 1 11 1 1 0 11 0 1 1 11 1 0 1 10 1 1 1 11 1 1 0 1
I want to have the code identify if
- there are three consecutive 1s in the first through third column, and
- that there are two sets of consecutive 1s in the fourth column.
I then want to compare this matrix with another matrix, and find where they are similar in the exact locations of the three consecutive 1s.
Best Answer