Skip to contents

Similarity

Usage

similarity(object, ...)

index_jaccard(x, y, ...)

index_sorenson(x, y, ...)

index_bray(x, y, ...)

index_morisita(x, y, ...)

index_brainerd(x, y, ...)

index_binomial(x, y, ...)

# S4 method for matrix
similarity(
  object,
  method = c("brainerd", "bray", "jaccard", "morisita", "sorenson", "binomial")
)

# S4 method for data.frame
similarity(
  object,
  method = c("brainerd", "bray", "jaccard", "morisita", "sorenson", "binomial")
)

# S4 method for character,character
index_jaccard(x, y)

# S4 method for logical,logical
index_jaccard(x, y)

# S4 method for numeric,numeric
index_jaccard(x, y)

# S4 method for logical,logical
index_sorenson(x, y)

# S4 method for numeric,numeric
index_sorenson(x, y)

# S4 method for numeric,numeric
index_bray(x, y)

# S4 method for numeric,numeric
index_morisita(x, y)

# S4 method for numeric,numeric
index_brainerd(x, y)

# S4 method for numeric,numeric
index_binomial(x, y)

Arguments

object

A \(m \times p\) matrix of count data.

...

Currently not used.

x, y

A length-\(p\) numeric vector of count data.

method

A character string specifying the method to be used (see details). Any unambiguous substring can be given.

Value

Details

\(\beta\)-diversity can be measured by addressing similarity between pairs of samples/cases (Brainerd-Robinson, Jaccard, Morisita-Horn and Sorenson indices). Similarity between pairs of taxa/types can be measured by assessing the degree of co-occurrence (binomial co-occurrence).

Jaccard, Morisita-Horn and Sorenson indices provide a scale of similarity from \(0\)-\(1\) where \(1\) is perfect similarity and \(0\) is no similarity. The Brainerd-Robinson index is scaled between \(0\) and \(200\). The Binomial co-occurrence assessment approximates a Z-score.

binomial

Binomial co-occurrence assessment. This assesses the degree of co-occurrence between taxa/types within a dataset. The strongest associations are shown by large positive numbers, the strongest segregations by large negative numbers.

brainerd

Brainerd-Robinson quantitative index. This is a city-block metric of similarity between pairs of samples/cases.

bray

Sorenson quantitative index (Bray and Curtis modified version of the Sorenson index).

jaccard

Jaccard qualitative index.

morisita

Morisita-Horn quantitative index.

sorenson

Sorenson qualitative index.

References

Brainerd, G. W. (1951). The Place of Chronological Ordering in Archaeological Analysis. American Antiquity, 16(04), 301-313. doi:10.2307/276979 .

Bray, J. R. & Curtis, J. T. (1957). An Ordination of the Upland Forest Communities of Southern Wisconsin. Ecological Monographs, 27(4), 325-349. doi:10.2307/1942268 .

Kintigh, K. (2006). Ceramic Dating and Type Associations. In J. Hantman and R. Most (eds.), Managing Archaeological Data: Essays in Honor of Sylvia W. Gaines. Anthropological Research Paper, 57. Tempe, AZ: Arizona State University, p. 17-26.

Magurran, A. E. (1988). Ecological Diversity and its Measurement. Princeton, NJ: Princeton University Press. doi:10.1007/978-94-015-7358-0 .

Robinson, W. S. (1951). A Method for Chronologically Ordering Archaeological Deposits. American Antiquity, 16(04), 293-301. doi:10.2307/276978 .

See also

Other diversity measures: heterogeneity(), occurrence(), plot_diversity, rarefaction(), richness(), simulate(), turnover()

Author

N. Frerebeau

Examples

## Data from Huntley 2008
ceramics <- matrix(
  data = c(16, 9, 3, 0, 1,
           13, 3, 2, 0, 0,
           9, 5, 2, 5, 0,
           14, 12, 3, 0, 0,
           0, 26, 4, 0, 0,
           1, 26, 4, 0, 0,
           0, 11, 3, 13, 0,
           0, 0, 17, 0, 16,
           0, 0, 18, 0, 14),
  nrow = 9, byrow = TRUE
)
rownames(ceramics) <- c("Atsinna", "Cienega", "Mirabal", "PdMuertos",
                        "Hesh", "LowPesc", "BoxS", "Ojo Bon", "S170")
colnames(ceramics) <- c("DLH-1", "DLH-2a", "DLH-2b", "DLH-2c", "DLH-4")

## Brainerd-Robinson measure
(C <- similarity(ceramics, "brainerd"))
#>             Atsinna   Cienega   Mirabal PdMuertos      Hesh   LowPesc      BoxS
#> Cienega   164.36782                                                            
#> Mirabal   152.38095 138.09524                                                  
#> PdMuertos 179.31034 150.57471 152.38095                                        
#> Hesh       82.75862  55.55556  66.66667 103.44828                              
#> LowPesc    89.21023  62.00717  73.11828 109.89989 193.54839                    
#> BoxS       82.75862  55.55556 114.28571 102.17114 103.70370 103.70370          
#> Ojo Bon    27.58621  22.22222  19.04762  20.68966  26.66667  25.80645  22.22222
#> S170       27.58621  22.22222  19.04762  20.68966  26.66667  25.80645  22.22222
#>             Ojo Bon
#> Cienega            
#> Mirabal            
#> PdMuertos          
#> Hesh               
#> LowPesc            
#> BoxS               
#> Ojo Bon            
#> S170      190.53030
plot_spot(C)


## Data from Magurran 1988, p. 166
birds <- matrix(
  data = c(1.4, 4.3, 2.9, 8.6, 4.2, 15.7, 2.0, 50, 1, 11.4, 11.4, 4.3, 13.0,
           14.3, 8.6, 7.1, 10.0, 1.4, 2.9, 5.7, 1.4, 11.4, 2.9, 4.3, 1.4, 2.9,
           0, 0, 0, 2.9, 0, 0, 0, 10, 0, 0, 5.7, 2.5, 5.7, 8.6, 5.7, 2.9, 0, 0,
           2.9, 0, 0, 5.7, 0, 2.9, 0, 2.9),
  nrow = 2, byrow = TRUE
)
rownames(birds) <- c("unmanaged", "managed")

## Jaccard measure (presence/absence data)
similarity(birds, "jaccard") # 0.46
#>         unmanaged
#> managed 0.4615385

## Sorenson measure (presence/absence data)
similarity(birds, "sorenson") # 0.63
#>         unmanaged
#> managed 0.6315789

# Jaccard measure (Bray's formula ; count data)
similarity(birds, "bray") # 0.44
#>         unmanaged
#> managed 0.4442754

# Morisita-Horn measure (count data)
similarity(birds, "morisita") # 0.81
#>         unmanaged
#> managed 0.8134497