[source, ruby]
----
response = client.search(
  index: 'exams',
  body: {
    size: 0,
    aggregations: {
      grades_stats: {
        extended_stats: {
          field: 'grade'
        }
      }
    }
  }
)
puts response
----
