Show / Hide Table of Contents

Class Stats

Factory functions for standard statistics strings.

Inheritance
object
Stats
Namespace: Amazon.CDK.AWS.CloudWatch
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public abstract class Stats : DeputyBase
Syntax (vb)
Public MustInherit Class Stats Inherits DeputyBase
Remarks

ExampleMetadata: infused

Examples
Dashboard dashboard;
            Metric executionCountMetric;
            Metric errorCountMetric;


            dashboard.AddWidgets(new GraphWidget(new GraphWidgetProps {
                Title = "Executions vs error rate",

                Left = new [] { executionCountMetric },

                Right = new [] { errorCountMetric.With(new MetricOptions {
                    Statistic = Stats.AVERAGE,
                    Label = "Error rate",
                    Color = Color.GREEN
                }) }
            }));

Synopsis

Constructors

Stats()

Factory functions for standard statistics strings.

Properties

AVERAGE

The value of Sum / SampleCount during the specified period.

IQM

Interquartile mean (IQM) is the trimmed mean of the interquartile range, or the middle 50% of values.

MAXIMUM

The highest value observed during the specified period.

MINIMUM

The lowest value observed during the specified period.

SAMPLE_COUNT

The count (number) of data points used for the statistical calculation.

SUM

All values submitted for the matching metric added together.

Methods

P(double)

A shorter alias for percentile().

Percentile(double)

Percentile indicates the relative standing of a value in a dataset.

PercentileRank(double, double?)

Percentile rank (PR) is the percentage of values that meet a fixed threshold.

Pr(double, double?)

Shorter alias for percentileRank().

Tc(double, double?)

Shorter alias for trimmedCount().

Tm(double, double?)

A shorter alias for trimmedMean().

TrimmedCount(double, double?)

Trimmed count (TC) is the number of data points in the chosen range for a trimmed mean statistic.

TrimmedMean(double, double?)

Trimmed mean (TM) is the mean of all values that are between two specified boundaries.

TrimmedSum(double, double?)

Trimmed sum (TS) is the sum of the values of data points in a chosen range for a trimmed mean statistic.

Ts(double, double?)

Shorter alias for trimmedSum().

WinsorizedMean(double, double?)

Winsorized mean (WM) is similar to trimmed mean.

Wm(double, double?)

A shorter alias for winsorizedMean().

Constructors

Stats()

Factory functions for standard statistics strings.

protected Stats()
Remarks

ExampleMetadata: infused

Examples
Dashboard dashboard;
            Metric executionCountMetric;
            Metric errorCountMetric;


            dashboard.AddWidgets(new GraphWidget(new GraphWidgetProps {
                Title = "Executions vs error rate",

                Left = new [] { executionCountMetric },

                Right = new [] { errorCountMetric.With(new MetricOptions {
                    Statistic = Stats.AVERAGE,
                    Label = "Error rate",
                    Color = Color.GREEN
                }) }
            }));

Properties

AVERAGE

The value of Sum / SampleCount during the specified period.

public static string AVERAGE { get; }
Property Value

string

Remarks

ExampleMetadata: infused

IQM

Interquartile mean (IQM) is the trimmed mean of the interquartile range, or the middle 50% of values.

public static string IQM { get; }
Property Value

string

Remarks

It is equivalent to trimmedMean(25, 75).

MAXIMUM

The highest value observed during the specified period.

public static string MAXIMUM { get; }
Property Value

string

Remarks

You can use this value to determine high volumes of activity for your application.

MINIMUM

The lowest value observed during the specified period.

public static string MINIMUM { get; }
Property Value

string

Remarks

You can use this value to determine low volumes of activity for your application.

SAMPLE_COUNT

The count (number) of data points used for the statistical calculation.

public static string SAMPLE_COUNT { get; }
Property Value

string

Remarks

ExampleMetadata: infused

SUM

All values submitted for the matching metric added together.

public static string SUM { get; }
Property Value

string

Remarks

This statistic can be useful for determining the total volume of a metric.

Methods

P(double)

A shorter alias for percentile().

public static string P(double percentile)
Parameters
percentile double
Returns

string

Remarks

ExampleMetadata: infused

Percentile(double)

Percentile indicates the relative standing of a value in a dataset.

public static string Percentile(double percentile)
Parameters
percentile double
Returns

string

Remarks

Percentiles help you get a better understanding of the distribution of your metric data.

For example, p(90) is the 90th percentile and means that 90% of the data within the period is lower than this value and 10% of the data is higher than this value.

PercentileRank(double, double?)

Percentile rank (PR) is the percentage of values that meet a fixed threshold.

public static string PercentileRank(double v1, double? v2 = null)
Parameters
v1 double
v2 double?
Returns

string

Remarks

    For example, percentileRank(300) returns the percentage of data points that have a value of 300 or less. percentileRank(100, 2000) returns the percentage of data points that have a value between 100 and 2000.

    Pr(double, double?)

    Shorter alias for percentileRank().

    public static string Pr(double v1, double? v2 = null)
    Parameters
    v1 double
    v2 double?
    Returns

    string

    Remarks

    ExampleMetadata: infused

    Tc(double, double?)

    Shorter alias for trimmedCount().

    public static string Tc(double p1, double? p2 = null)
    Parameters
    p1 double
    p2 double?
    Returns

    string

    Remarks

    ExampleMetadata: infused

    Tm(double, double?)

    A shorter alias for trimmedMean().

    public static string Tm(double p1, double? p2 = null)
    Parameters
    p1 double
    p2 double?
    Returns

    string

    Remarks

    ExampleMetadata: infused

    TrimmedCount(double, double?)

    Trimmed count (TC) is the number of data points in the chosen range for a trimmed mean statistic.

    public static string TrimmedCount(double p1, double? p2 = null)
    Parameters
    p1 double
    p2 double?
    Returns

    string

    Remarks

      For example, tc(90) returns the number of data points not including any data points that fall in the highest 10% of the values. tc(10, 90) returns the number of data points not including any data points that fall in the lowest 10% of the values and the highest 90% of the values.

      TrimmedMean(double, double?)

      Trimmed mean (TM) is the mean of all values that are between two specified boundaries.

      public static string TrimmedMean(double p1, double? p2 = null)
      Parameters
      p1 double
      p2 double?
      Returns

      string

      Remarks

      Values outside of the boundaries are ignored when the mean is calculated. You define the boundaries as one or two numbers between 0 and 100, up to 10 decimal places. The numbers are percentages.

        For example, tm(90) calculates the average after removing the 10% of data points with the highest values; tm(10, 90) calculates the average after removing the 10% with the lowest and 10% with the highest values.

        TrimmedSum(double, double?)

        Trimmed sum (TS) is the sum of the values of data points in a chosen range for a trimmed mean statistic.

        public static string TrimmedSum(double p1, double? p2 = null)
        Parameters
        p1 double
        p2 double?
        Returns

        string

        Remarks

        It is equivalent to (Trimmed Mean) * (Trimmed count).

          For example, ts(90) returns the sum of the data points not including any data points that fall in the highest 10% of the values. ts(10, 90) returns the sum of the data points not including any data points that fall in the lowest 10% of the values and the highest 90% of the values.

          Ts(double, double?)

          Shorter alias for trimmedSum().

          public static string Ts(double p1, double? p2 = null)
          Parameters
          p1 double
          p2 double?
          Returns

          string

          Remarks

          ExampleMetadata: infused

          WinsorizedMean(double, double?)

          Winsorized mean (WM) is similar to trimmed mean.

          public static string WinsorizedMean(double p1, double? p2 = null)
          Parameters
          p1 double
          p2 double?
          Returns

          string

          Remarks

          However, with winsorized mean, the values that are outside the boundary are not ignored, but instead are considered to be equal to the value at the edge of the appropriate boundary. After this normalization, the average is calculated. You define the boundaries as one or two numbers between 0 and 100, up to 10 decimal places.

            For example, tm(90) calculates the average after removing the 10% of data points with the highest values; tm(10, 90) calculates the average after removing the 10% with the lowest and 10% with the highest values.

            For example, wm(90) calculates the average while treating the 10% of the highest values to be equal to the value at the 90th percentile. wm(10, 90) calculates the average while treaing the bottom 10% and the top 10% of values to be equal to the boundary values.

            Wm(double, double?)

            A shorter alias for winsorizedMean().

            public static string Wm(double p1, double? p2 = null)
            Parameters
            p1 double
            p2 double?
            Returns

            string

            Remarks

            ExampleMetadata: infused

            Back to top Generated by DocFX