mses: Mean Squared Error

Description Usage Arguments Details Value References Examples

Description

As part of the Monte Carlo investigation of the relative efficency between estimators for finite sample sizes, this function calculates the sum of squared differences of the inputted sample observations against the value of theta0. The sum is divided by size of the sample n.

Usage

1
mses(x, theta0 = 0)

Arguments

x

A numeric vector containing sample size n

theta0

Variance of sample x

Details

The Monte Carlo investigation of relative efficency between estimators for finite sample sizes is covered in Section 10.3.4 on page 595.

Value

The mean squared error of the inputted sample and value for theta.

References

Hogg, R., McKean, J., Craig, A. (2018) Introduction to Mathematical Statistics, 8th Ed. Boston: Pearson.

Examples

1
2
3
4
5
6
7
8
sample1 <- rcn(n = 30, eps = 0.20, sigma_c = 25)
sample2 <- rcn(n = 20, eps = 0.20, sigma_c = 25)

theta1 <- var(sample1)
theta2 <- var(sample2)

MSE1 <- mses(sample1, theta1)
MSE2 <- mses(sample2, theta2)

austinragotzy/mathstat documentation built on May 13, 2019, 11:30 a.m.