EM: Runs the EM algorithm.

Description Usage Arguments Value Author(s) Examples

View source: R/EM.R

Description

Attributes to the populations in an invasion time series a probability value of being of natural origin, as opposite of anthropogenic origin.

Usage

1
EM(dataset, randompoints, sigma, pi)

Arguments

dataset

the data frame to be analised (WGS84, colums order should be "year","lat","long","origin")

randompoints

data frame of 'y' and 'x' coordinates of random points (projected coordinate system)

sigma

starting value for the standard deviation of the natural dispersal kernel (assumed to be a half normal)

pi

starting value for the proportion of natural points in the dataset

Value

dataset argument with two additional colums. 'dist': distance from nearest point of natural origin or nearest anchor point (see Details); 'Pnat': probability of being of natural origin.

Author(s)

Beatrix Jones, Luca Butikofer

Examples

1
2
3
4
data('nzp')
data('frogs')
randp<- RPG(rpopn=1000, boundary=nzp, SP= 'random_frog')
frogsEM<- EM(dataset= frogs, randompoints= randp, sigma=6, pi=0.5)

Biolinv documentation built on March 30, 2021, 5:13 p.m.

Related to EM in Biolinv...