Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-680

StatsComponent - get min, max, sum, qt, avg of number fields

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 1.4
    • search
    • None

    Description

      StatsComponent - it returns min,max,sum,qt,avg of specified number fields:

      request parameters:
      &stats=on&stats.field=price

      <stats>
       <stats_fields>
         <lst name="price">
             <double name="min">10</double>
             <double name="max">30</double>
             <double name="avg">20</double>
             <double name="sum">60</double>
             <double name="qt">3</double>
         </lst>
       </stats_fields>
      </stats>
      

      WRT "stats", the component can output sum and avg, but not sd and var.

      USE CASE:
      StatsComponent can be used to get "market price" of DocSet e.g. rental housing site, package tour site.

      Attachments

        1. SOLR-680.patch
          15 kB
          Harish Agarwal
        2. SOLR-680.patch
          34 kB
          Ryan McKinley
        3. SOLR-680.patch
          28 kB
          Ryan McKinley
        4. SOLR-680.patch
          26 kB
          Ryan McKinley
        5. SOLR-680.patch
          22 kB
          Ryan McKinley
        6. SOLR-680.patch
          16 kB
          Ryan McKinley
        7. SOLR-680.patch
          12 kB
          Koji Sekiguchi
        8. SOLR-680-remove-bad-median-calculation.patch
          6 kB
          Ryan McKinley

        Issue Links

          Activity

            People

              ryantxu Ryan McKinley
              koji Koji Sekiguchi
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: