rcpp_dispersal_placement: dispersal function in rcpp

View source: R/RcppExports.R

rcpp_dispersal_placementR Documentation

dispersal function in rcpp

Description

a quick rcpp based implementation because the abind in the R implementation gobbles up a lot of time. For this you just pass in a vector for pop1 and a vector for pop2 that says where each individual goes. That way we can do the individual selection outside of this function.

Usage

rcpp_dispersal_placement(P1, P2, d1, d2, a1, a2)

Arguments

P1

first pop struct, indexed by indiv, locus, gene copy

P2

second pop struct

d1

dim of first pop struct

d2

dim of second pop struct

a1

assignments of individuals in pop 1 to either pop 1 or 2

a2

assignments of individuals in pop 2 to either pop 1 or 2


eriqande/glads documentation built on Jan. 26, 2024, 9:25 p.m.