Skip to main content

opensearch_client/common/aggregations/
matrix_stats_fields.rs

1/*
2 * opensearch-client
3 *
4 * Rust Client for OpenSearch
5 *
6 * The version of the OpenAPI document: 3.1.0
7 * Contact: alberto.paro@gmail.com
8 * Generated by Paro OpenAPI Generator
9 */
10
11use crate::common;
12use serde::{Deserialize, Serialize};
13
14
15
16
17#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
18pub struct MatrixStatsFields {
19    #[serde(rename = "skewness")]
20    pub skewness: f64,  /// The path to a field or an array of paths. Some APIs support wildcards in the path, which allows you to select multiple fields.
21    #[serde(rename = "name")]
22    pub name: String,
23    #[serde(rename = "correlation")]
24    pub correlation: serde_json::Value,
25    #[serde(rename = "count")]
26    pub count: f64,
27    #[serde(rename = "variance")]
28    pub variance: f64,
29    #[serde(rename = "kurtosis")]
30    pub kurtosis: f64,
31    #[serde(rename = "mean")]
32    pub mean: f64,
33    #[serde(rename = "covariance")]
34    pub covariance: serde_json::Value,
35}
36
37impl MatrixStatsFields {
38    
39    pub fn new(skewness: f64, name: String, correlation: serde_json::Value, count: f64, variance: f64, kurtosis: f64, mean: f64, covariance: serde_json::Value) -> MatrixStatsFields {
40        MatrixStatsFields {
41            skewness,
42            name,
43            correlation,
44            count,
45            variance,
46            kurtosis,
47            mean,
48            covariance,
49        }
50    }
51}