Its always showing `Not enough data to calculate...
# community-support
r
Its always showing
Not enough data to calculate anomaly score
I tried different anomaly_sensitivity from 1.5 to 2 Nothing is working out
Copy code
models:
  - name: metric_cal
    config:
      elementary:
        timestamp_column: 'metric_date'
    columns:
      - name: metric_value
        tests:
          - elementary.column_anomalies:
              column_anomalies:
                - sum
              time_bucket:
                period: month
                count: 1
              days_back: 426
              config:
                severity: ERROR
              anomaly_sensitivity: 2
              where_expression: "product_name = 'Transactions' "
d
Hey @Ram, Do you have available data for 426 days back ?
r
Yes
we have data all way from 2012
@Daniel Pollak Any updates regarding about issues
@Daniel Pollak I am have been for long
m
Hey @Ram,
min_training_set_size
is by default 14. As we truncate to full months, 426 days probably result in 13 buckets. you can change the default, see here how: https://docs.elementary-data.com/data-tests/anomaly-detection-configuration/min-training-set-size
r
@Maayan Salom I tried as you mentioned added
min_training_set_size:13
Still i see Not enough data to calculate anomaly score.
image.png
Copy code
models:
  - name: metric_cal
    config:
      elementary:
        timestamp_column: 'metric_date'
    columns:
      - name: metric_value
        tests:
          - elementary.column_anomalies:
              min_training_set_size: 13
              column_anomalies:
                - sum
              time_bucket:
                period: month
                count: 1
              days_back: 426
              config:
                severity: ERROR
              anomaly_sensitivity: 2
              where_expression: "product_name = 'Transactions' "
Anything am I missing ?
m
Did you run the test with this config and produced a new report? Also if there is no data the bucket will be missing. I suggest you try it with min training of 3 for example to see it is working
r
Yes ran the dbt test and then edr report
we have data from 2012
Tried with min_training_set_size: 3
Same error