title: Checking if a ruby hash contains a value greater than x
body: <p>I have the following object returned from an InfluxDB query, and I want to be able to check if any of the derivatives are equal or greater than say 100, if so then do stuff.</p>
  
  <p>I've been trying to use select to check that field, but I really don't actually understand how to work with a data structure like this. How would I go about iterating through every derivative value in my returned object?</p>
  
  <p>I'm not really seeing an example that's similar to my case in the enumerable documentation.
  <a href="https://ruby-doc.org/core-2.4.0/Enumerable.html" rel="nofollow noreferrer">https://ruby-doc.org/core-2.4.0/Enumerable.html</a></p>
  
  <pre><code> [{
     "name" =&gt; "powerdns_value", 
               "tags" =&gt; nil,
               "values" =&gt; [
                 { "time" =&gt; "2017-03-21T14:20:00Z", "derivative" =&gt; 1}, 
                 { "time" =&gt; "2017-03-21T14:30:00Z", "derivative" =&gt; 900}, 
                 { "time" =&gt; "2017-03-21T14:40:00Z", "derivative" =&gt; 0},  
                 { "time" =&gt; "2017-03-21T15:20:00Z", "derivative" =&gt; 0}
               ]
  }]
  </code></pre>