Learn R Programming

LCCR (version 2.0.1)

freq_data: Convert capture-recapture configurations into frequency data

Description

Given a matrix of observed capture-recapture configurations, convert the data to a matrix of frequencies having the same number of rows and a number of columns equal to the number of possible configurations.

Usage

freq_data(R,count=rep(1,nrow(R)))

Value

Y

Matrix of frequency of each capture configuration of size n x (2^J)

Arguments

R

Matrix of size n (sample size) x J (number of capture occastions) of observed capture-recapture configurations

count

Vector of counts for each configuration

Author

Francesco Bartolucci, Antonio Forcina

See Also

aggr_data

Examples

Run this code
R = rbind(c(0,0,0,1),c(0,1,0,0),c(0,0,1,1),c(1,1,1,1),c(1,1,1,1))
Y = freq_data(R)

Run the code above in your browser using DataLab