Last active
October 21, 2015 02:32
-
-
Save arunreddy/daafd14e5a5b4ff9af29 to your computer and use it in GitHub Desktop.
Replacing negative values with zeroes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| a = [1 -2 ; -3 4]; | |
| aPos = (a.>0.0).*a; | |
| aInd = (a.<0.0).*a*-1; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment