bootstrap Function

public function bootstrap(stat, x, method, nsamples, alpha) result(rst)

Performs a bootstrap calculation on the supplied data set for the given statistic. The default implementation utlizes a random resampling with replacement. Other resampling methods may be defined by specifying an appropriate routine by means of the method input.

Arguments

Type IntentOptional Attributes Name
procedure(bootstrap_statistic_routine), intent(in), pointer :: stat

The routine used to compute the desired statistic.

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

The N-element data set.

procedure(bootstrap_resampling_routine), intent(in), optional, pointer :: method

An optional pointer to the method to use for resampling of the data. If no method is supplied, a random resampling is utilized.

integer(kind=int32), intent(in), optional :: nsamples

An optional input, that if supplied, specifies the number of resampling runs to perform. The default is 10 000.

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

An optional input, that if supplied, defines the significance level to use for the analysis. The default is 0.05.

Return Value type(bootstrap_statistics)

The resulting bootstrap_statistics type containing the confidence intervals, bias, standard error, etc. for the analyzed statistic.


Contents