bayes {DATRAS}R Documentation

Calculate conditional expectation of some function of length given age.

Description

Calculate conditional expectation of some function of length given age.

Usage

  bayes(pal, pl, fl)

Arguments

pal

matrix with age-length key, i.e. p(A|L). Columns correspond to age groups.

pl

vector with length distribution, i.e. p(L).

fl

vector of function values at length, i.e. f(L).

Details

Find E(f(L)|A) in terms of p(L), p(A|L) and f(L), using Bayes formula.

Value

vector of expectations


[Package DATRAS version 1.0 Index]