Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
Questions on filtering or selecting data based on certain criteria. This is to be used with primary tags such as list-manipulation, string-manipulation or signal-processing, with the primary tag indicating the specific use case.
5
votes
Accepted
position of rows (or columns) whose elements all satisfy a condition
Use the function VectorQ,
A = {{-1, 2, 3}, {4, 5, 6}, {-7, 8, 9}};
Position[A, x_ /; VectorQ[x, # > 0 &], {1}]
or
Position[VectorQ[#, # > 0 &] & /@ A, True, {1}]
As Mr.Wizard points out that you …