fstats_descriptive_statistics Module



Contents


Interfaces

public interface pooled_variance

Computes the pooled estimate of variance.

  • private pure function pooled_variance_1(si, ni) result(rst)

    Computes the pooled estimate of variance.

    Arguments

    Type IntentOptional Attributes Name
    real(kind=real64), intent(in), dimension(:) :: si

    An N-element array containing the estimates for each of the N variances.

    integer(kind=int32), intent(in), dimension(size(si)) :: ni

    An N-element array containing the number of data points in each of the data sets used to compute the variances in si.

    Return Value real(kind=real64)

    The pooled variance.

  • private pure function pooled_variance_2(x) result(rst)

    Computes the pooled estimate of variance.

    Arguments

    Type IntentOptional Attributes Name
    type(array_container), intent(in), dimension(:) :: x

    An array of arrays of data.

    Return Value real(kind=real64)

    The pooled variance.


Functions

public pure function covariance(x, y) result(rst)

Computes the sample covariance of two data sets.

Read more…

Arguments

Type IntentOptional Attributes Name
real(kind=real64), intent(in), dimension(:) :: x

The first N-element data set.

real(kind=real64), intent(in), dimension(size(x)) :: y

The second N-element data set.

Return Value real(kind=real64)

The covariance.

public pure function mean(x) result(rst)

Computes the mean of the values in an array.

Arguments

Type IntentOptional Attributes Name
real(kind=real64), intent(in) :: x(:)

The array of values to analyze.

Return Value real(kind=real64)

The result.

public function median(x) result(rst)

Computes the median of the values in an array.

Arguments

Type IntentOptional Attributes Name
real(kind=real64), intent(inout) :: x(:)

The array of values to analyze. On output, this array is sorted into ascending order.

Return Value real(kind=real64)

The result.

public pure function quantile(x, q) result(rst)

Computes the specified quantile of a data set using the SAS Method 4.

Read more…

Arguments

Type IntentOptional Attributes Name
real(kind=real64), intent(in) :: x(:)

An N-element array containing the data.

real(kind=real64), intent(in) :: q

The quantile to compute (e.g. 0.25 computes the 25% quantile).

Return Value real(kind=real64)

The result.

public pure function standard_deviation(x) result(rst)

Computes the sample standard deviation of the values in an array.

Read more…

Arguments

Type IntentOptional Attributes Name
real(kind=real64), intent(in) :: x(:)

The array of values to analyze.

Return Value real(kind=real64)

The result.

public function trimmed_mean(x, p) result(rst)

Computes the trimmed mean of a data set.

Arguments

Type IntentOptional Attributes Name
real(kind=real64), intent(inout), dimension(:) :: x

An N-element array containing the data. On output, the array is sorted into ascending order.

real(kind=real64), intent(in), optional :: p

An optional parameter specifying the percentage of values from either end of the distribution to remove. The default is 0.05 such that the bottom 5% and top 5% are removed.

Return Value real(kind=real64)

The trimmed mean.

public pure function variance(x) result(rst)

Computes the sample variance of the values in an array.

Read more…

Arguments

Type IntentOptional Attributes Name
real(kind=real64), intent(in) :: x(:)

The array of values to analyze.

Return Value real(kind=real64)