title: How to run array_filter recursively in a PHP array?
body: <p>Given the following array <code>$mm</code></p>
  
  <pre><code>Array
  (
      [147] =&gt; Array
          (
              [pts_m] =&gt; 
              [pts_mreg] =&gt; 1
              [pts_cg] =&gt; 1
          )    
      [158] =&gt; Array
          (
              [pts_m] =&gt; 
              [pts_mreg] =&gt; 
              [pts_cg] =&gt; 0
          )
  
      [159] =&gt; Array
          (
              [pts_m] =&gt; 
              [pts_mreg] =&gt; 1
              [pts_cg] =&gt; 1
          )
  
  )
  </code></pre>
  
  <p>When I run <code>count(array_filter($mm))</code> I get <code>3</code> as result since it is not recursive.</p>
  
  <p><code>count(array_filter($mm), COUNT_RECURSIVE)</code> also will not do because I actually need to run the <code>array_filter</code> recursively, and then count its result.</p>
  
  <p>So my question is: how do I recursively run <code>array_filter($mm)</code> in this case? 
  My expected result here would be <code>4</code>.</p>
  
  <p>Please note that I am not using any callback so I can exclude false, null and empty.</p>