Difference between revisions of "MATLAB talk:Logical Masks"
Jump to navigation
Jump to search
Line 1: | Line 1: | ||
Hi this is Everett Loving. | Hi this is Everett Loving. | ||
− | When a logical mask is scanning a matrix of numbers, is it possible to ask the mask to check for two conditions? For example: | + | When a logical mask is scanning a matrix of numbers, is it possible to ask the mask to check for two conditions? For example, something like: |
− | |||
variable = (condition && condition) .*value +... | variable = (condition && condition) .*value +... | ||
− | + | (condition) ..... |
Revision as of 03:59, 20 September 2012
Hi this is Everett Loving. When a logical mask is scanning a matrix of numbers, is it possible to ask the mask to check for two conditions? For example, something like:
variable = (condition && condition) .*value +... (condition) .....