The Search/Analytics feature of Log Service allows you to use mathematical statistic functions to analyze logs. The following table describes the supported mathematical statistic functions.
Statement | Description | Example |
---|---|---|
corr(y, x) |
Returns the correlation coefficient of input values. The result ranges from 0 to 1. | latency>100| select
corr(latency,request_size) |
covar_pop(y, x) |
Returns the population covariance of input values. | latency>100| select
covar_pop(request_size,latency) |
covar_samp(y, x) |
Returns the sample covariance of input values. | latency>100| select
covar_samp(request_size,latency) |
regr_intercept(y, x) |
Returns the linear regression intercept of input values. y is the dependent value. x is the independent value. | latency>100| select
regr_intercept(request_size,latency) |
regr_slope(y,x) |
Returns the linear regression slope of input values. y is the dependent value. x is the independent value. | latency>100| select
regr_slope(request_size,latency) |
stddev(x) or stddev_samp(x) |
Returns the sample standard deviation of all input values. | latency>100| select stddev(latency) |
stddev_pop(x) |
Returns the population standard deviation of all input values. | latency>100| select stddev_pop(latency) |
variance(x) or
var_samp(x) |
Returns the sample variance of all input values. | latency>100| select variance(latency) |
var_pop(x) |
Returns the population variance of all input values. | latency>100| select variance(latency) |