transect_clustering: Estimate spatial clustering

View source: R/transect_clustering.R

transect_clusteringR Documentation

Estimate spatial clustering

Description

Estimate the degree of spatial clustering along a transect

Usage

transect_clustering(genotypes, positions, deme_size = 30)

Arguments

genotypes

Vector of genotype labels

positions

Vector of positions along a linear transect. Should be the same length as genotypes.

Details

transect_clustering estimates the degree of non-randomness in the distribution of genotypes along a linear transect by comparing the mean pairwise distances between sampling points with the same genotype to mean pairwise distances between sampling points with non-identical genotypes.

Value

A vector of three elements giving the number of pairs of identical and non-identical gentotypes in the transect, and the Pearson correlation coefficient between distance and pairwise identity.

Author(s)

Tom Ellis


ellisztamas/simmiad documentation built on Dec. 12, 2023, 5:32 a.m.