[eigen] find command or equivalent

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


I want to replace all elements of a matrix, which are less than a threshold by zero. How to do it without writing a nested for loop?

I am looking for something like this in matlab. A(A < 0.001) = 0 where A is a matrix.


R Suresh Kumar,
Dhyaana–moolam Guror murtih
Puja-moolam Guroh padam
Mantra – moolam Guror vakyam
Moksha – moolam Guroh krpa.

Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/