title: Sum Aggregation ignores negative values
body: <p>I have mapped on elasticsearch a type called <code>measure</code>, which contains both sensorId and value as string.</p>
  
  <p>Mapping.</p>
  
  <pre><code>{
      "measures": {
          "mappings": {
              "summarizedmeasure": {
                  "properties": {
                      "sensorId": {
                          "type": "string"
                      }
                      "timestamp": {
                          "type": "date",
                          "format": "dateOptionalTime"
                      },
                      "value": {
                          "type": "string"
                      }
                  }
              }
          }
      }
  }
  </code></pre>
  
  <p>There are some negative values indexed, but when I calculate Sum Aggregated by Days It's giving positive value.</p>
  
  <pre><code>{
    "query": {
      "bool": {
        "must": 
          {
            "match": {
              "sensorId": "123"
            }
          }
      }
    },
    "aggs": {
      "value_per_day": {
        "date_histogram": {
          "field": "timestamp",
          "interval": "day"
        },
        "aggs": {
          "total": {
            "sum": {
              "script": "Float.parseFloat(doc['value'].value)"
            }
          }
        }
      }
    }
  }
  </code></pre>
  
  <p>Please help me to solve this issue. Thank you</p>