Calculates Agreement and Area using stratified estimators

aa_stratified(stratum, reference, map, h = NULL, N_h = NULL, fpc = F)

Arguments

stratum

vector of stratum identifiers

reference

vector of reference class labels

map

vector of map class labels

h

vector of unique stratum identifiers that correspond to N_h

N_h

number of samples (area) for each stratum h

fpc

finite population correction

Value

list of accuracy and area proportion estimates and associated standard errors

Details

Stratified estimation of map accuracy and area

References

Stehman, S. V., 2014. Estimating area and map accuracy for stratified random sampling when the strata are different from the map classes. Int. J. Remote Sens. 35, 4923-4939. https://doi.org/10.1080/01431161.2014.930207

Author

Dirk Pflugmacher

Examples

  
r <- c("A","A","A","A","A","C","B","A","B","C","A","B","B","B","B","B",
       "A","A","B","B","C","C","C","C","C","D","D","B","B","A","D","D",
        "D","D","D","D","D","C","C","B")
m <- c("A","A","A","A","A","A","A","B","B","B","A","B","B","B","B","B",
       "B","B","B","B","B","B","C","C","C","C","C","C","B","B","D","D",
       "D","D","D","D","D","D","D","D")
s <- c("1","1","1","1","1","1","1","1","1","1","2","2","2","2","2","2",
       "2","2","2","2","3","3","3","3","3","3","3","3","3","3","4","4",
       "4","4","4","4","4","4","4","4")
h <- c("1", "2", "3", "4")
N_h <- c(40000, 30000, 20000, 10000)
aa_stratified(s, r, m, h=h, N_h=N_h)
#> $cm
#>     A    B   C   D
#> A 9.2  1.6 1.6 0.0
#> B 4.8 10.8 3.2 0.0
#> C 0.0  0.8 2.4 1.6
#> D 0.0  0.4 0.8 2.8
#> 
#> $cmp
#>      A    B    C    D
#> A 0.23 0.04 0.04 0.00
#> B 0.12 0.27 0.08 0.00
#> C 0.00 0.02 0.06 0.04
#> D 0.00 0.01 0.02 0.07
#> 
#> $stats
#>   class        ua     ua_se        pa     pa_se        f1      f1_se
#> 1     A 0.7419355 0.1645627 0.6571429 0.1477318 0.6969697 0.11034620
#> 2     B 0.5744681 0.1248023 0.7941176 0.1165671 0.6666667 0.09354009
#> 3     C 0.5000000 0.2151657 0.3000000 0.1504438 0.3750000 0.13219833
#> 4     D 0.7000000 0.1527525 0.6363636 0.1623242 0.6666667 0.11284328
#> 
#> $accuracy
#> [1] 0.63000000 0.08465617
#> 
#> $fpc
#> [1] 1 1 1 1
#> 
#> $area
#>   class proportion proportion_se
#> 1     A       0.35    0.08225975
#> 2     B       0.34    0.07586538
#> 3     C       0.20    0.06429101
#> 4     D       0.11    0.03073181
#>