title: Elastic Search Statistical Facets - Aggregation
body: <p>So I have an index containing a 82 documents like the following (sample data to familiarise me with the api). </p>
  
  <pre><code>{"_index":"foo","_type":"bar","_id":"3675293","_score":1.0, "_source" : {
    "companyId": 3675293,
    "companyName": "ABC",
    "companyOwner": {
      "ownerFirstName": "Billy",
      "ownerLastName": "Jean"
    },
    "created": "2013-05-22T13:45:49",
    "accounts": [
      {
        "year": 2013,
        "amount": 1.0,
        "currency": "GBP"
      },
      {
        "year": 2012,
        "amount": 1.0,
        "currency": "GBP"
      }
    ]
  }}
  </code></pre>
  
  <p>The problem I have is that I'm trying to total all of the amounts. When I use a Statistical Facet via the NEST .Net client I get an answer I wouldn't expect. </p>
  
  <p>82 documents, each with a collection containing 2 amount of £1 in my mind aggregates to a total of 2 X 82 = 164. However, the facet returns a total of 82. When I change one of the amounts in each of the two documents to be 2 instead of 1, I get the correct result.</p>
  
  <p>Does Elastic Search only aggregate unique numerical values per document? Can this be overriden?</p>
  
  <p>Thanks
  Tim</p>