README.md in trend-0.1.0 vs README.md in trend-0.1.1

- old
+ new

@@ -1,18 +1,20 @@ # Trend -Ruby client for [Trend](https://trendapi.org), the time series API +Ruby client for [Trend](https://trendapi.org), the anomaly detection and forecasting API +[![Build Status](https://travis-ci.org/ankane/trend.svg?branch=master)](https://travis-ci.org/ankane/trend) + ## Getting Started Add this line to your application’s Gemfile: ```ruby gem 'trend' ``` -### Anomalies +### Anomaly Detection Detect anomalies in a time series ```ruby # generate series @@ -34,11 +36,11 @@ ```ruby series = User.group_by_day(:created_at).count Trend.anomalies(series) ``` -### Forecast +### Forecasting Get future predictions for a time series ```ruby series = {} @@ -60,9 +62,27 @@ Specify the number of predictions to return ```ruby Trend.forecast(series, count: 3) +``` + +### Correlation [experimental] + +Get the correlation between two time series + +```ruby +Trend.correlation(series, series2) +``` + +## Authentication + +An API key is needed for more than 1000 requests per day per IP. [Email us](mailto:hi@trendapi.org) to get one. + +If you have one, set `ENV["TREND_API_KEY"]` or use: + +```ruby +Trend.api_key = "secret" ``` ## History View the [changelog](https://github.com/ankane/trend/blob/master/CHANGELOG.md)