title: Finding Highest Value in Associative Array
body: <p>Is there a relatively easy way to find the highest values for each of the keys in my associative arrays?</p>
  
  <pre><code>Array(
  
      0 =&gt; Array(
          "avgtime"   =&gt; 19.75,
          "bounces"   =&gt; 3,
          "pageviews" =&gt; 14,
          "visitors"  =&gt; 4
      )
  
      1 =&gt; Array(
          "avgtime"   =&gt; 1.125,
          "bounces"   =&gt; 7,
          "pageviews" =&gt; 9,
          "visitors"  =&gt; 8
      )
  
      2 =&gt; Array(
          "avgtime"   =&gt; 111,
          "bounces"   =&gt; 18,
          "pageviews" =&gt; 32,
          "visitors"  =&gt; 20
      )
  
      3 =&gt; Array(
          "avgtime"   =&gt; 6.9375,
          "bounces"   =&gt; 14,
          "pageviews" =&gt; 18,
          "visitors"  =&gt; 10   
      )
  
      4 =&gt; Array(
          "avgtime"   =&gt; 191,
          "bounces"   =&gt; 11,
          "pageviews" =&gt; 57,
          "visitors"  =&gt; 24
      )
  );
  </code></pre>
  
  <p>I want to create one array that holds the highest value for each key so the end result would be.  </p>
  
  <pre><code>Array(
  
      "avgtime"   =&gt; 191,
      "bounces"   =&gt; 18,
      "pageviews" =&gt; 57,
      "visitors"  =&gt; 24
  );
  </code></pre>