Simulated tax refund data frame including the estimated and actual refund value

data(tax)

Format

A data frame with 9083 observations on the following 5 variables.

id

a numeric vector indicating the tax payer

estRefund

a numeric vector representing the estimated value of tax refund by the tax payer

actRefund

a numeric vector representing the actual tax refund calculated by the financial authority

diff

difference between estimated and acture tax refund

Class

a factor with levels 1, 2, 3, and 4 indicating the strata

Source

Due to data protection this is a simulated data set reflecting the real data.

References

Kauermann, Goeran/Kuechenhoff, Helmut (2010): Stichproben. Methoden und praktische Umsetzung mit R. Springer.

Examples

data(tax) summary(tax)
#> id estRefund actRefund diff #> Min. : 1 Min. : 0.27 Min. : 0.00 Min. : 0.0 #> 1st Qu.:2272 1st Qu.: 124.77 1st Qu.: 76.31 1st Qu.: 0.0 #> Median :4542 Median : 543.23 Median : 378.08 Median : 0.0 #> Mean :4542 Mean : 3842.28 Mean : 3227.43 Mean : 614.9 #> 3rd Qu.:6812 3rd Qu.: 2246.06 3rd Qu.: 1756.24 3rd Qu.: 0.0 #> Max. :9083 Max. :200504.35 Max. :178104.99 Max. :129520.4 #> Class #> Length:9083 #> Class :character #> Mode :character #> #> #>
# illustration of stratamean nh <- as.vector(table(tax$Class)) wh <- nh/sum(nh) stratamean(y=tax$diff, h=as.vector(tax$Class), wh=wh, eae=TRUE)
#> Mean SE CIu CIo #> 1 40.36435 1.623603 37.18214 43.54655 #> 2 480.43275 24.026405 433.34186 527.52364 #> 3 3840.83780 312.559990 3228.23147 4453.44412 #> 4 11161.88331 2216.524710 6817.57471 15506.19191 #> overall 614.85125 40.010241 536.43262 693.26988