genetic_autocorrelation: Performs 'Autocorrelation Analysis

View source: R/genetic_autocorrealtion.R

genetic_autocorrelationR Documentation

Performs 'Autocorrelation Analysis

Description

This function takes two distance matrices, one for physical separation and the other for genetic separation as well as a bin size and performs the spatial autocorrelation analysis of Smouse & Peakall (1999).

Usage

genetic_autocorrelation(P, G, bins, perms = 0, plot = FALSE)

Arguments

P

A square physical distance matrix

G

A square genetic distance matrix (same size as P)

bins

The distance bins to be estimated. These will be taken sequentially such that the first bin will be all observations whose separation is greater than binsize[1] and less than binsize[2].

perms

The number of permutations to use to test significance at each distance bin.

plot

A flag (default=FALSE) to show distribution of randomized correlations.

Value

A data.frame with bins and correlations.

Author(s)

Rodney J. Dyer rjdyer@vcu.edu


dyerlab/gstudio documentation built on Feb. 2, 2024, 8:24 p.m.