hawk.dove: Analysis of hawk-dove game theoretic model

View source: R/games.R

hawk.doveR Documentation

Analysis of hawk-dove game theoretic model

Description

This function performs numerical analysis of a discrete-time hawk-dove model in which "payoff" determines relative fitness in the population.

Usage

	hawk.dove(p=c(0.01,0.99), M=NULL, time=100)

Arguments

p

Starting frequency of hawk & dove phenotypes, respectively. Should correspond with the rows of M. If a single value is given then p will automatically be set to p=c(p,1-p).

M

Payoff matrix. M[i,j] should contain the fitness of i when interacting with j.

time

Number of generations.

Value

The function creates a two panel plot. The upper panel shows the relative frequencies of each of the two interacting phenotypes. The lower panel shows mean fitness of the population and of each morph through time.

The function also invisibly returns an object of class "hawk.dove" containing the frequencies of each strategy through time and their fitnesses. This object can be printed or re-plotted using corresponding print and plot methods. (See examples.)

Author(s)

Liam Revell liam.revell@umb.edu

See Also

freqdep

Examples

	hawk.dove(time=60)
	Payoff<-matrix(c(0.5,0.6,1.5,1.0),2,2)
	object<-hawk.dove(M=Payoff,time=60)
	print(object)
	plot(object)

liamrevell/PopGen documentation built on Jan. 4, 2023, 10:02 p.m.