MATLAB: Picking rows which has negative element.

matrix

hi, i have a matrix which can have negative elements. is ther eq quick and efficient way to pick the rows if any element in the row has negative values.
Thanks

Best Answer

Hi
a=randn([5 5])+1
Nrows=sum(a<0,2);
a(Nrows>0,:)