Learn R Programming

phenology (version 7.2)

plot.ECFOCF: Plot a result of clutch frequency fit.

Description

This function plots the result of fitCF(). The result data plots the observed ECF-OCF table. The result dataOCF plots the observed OCF table. The result dataECF plots the observed ECF table. The result CF plots the true clutch frequency. The result OCF plots the observed clutch frequency. The result ECF plots the estimated clutch frequency. The result ECFOCF plots the bivariate observed vs. estimated clutch frequency. The result ECFOCF0 plots the bivariate observed vs. estimated clutch frequency without the 0 OCF. The result prob plots the probabilities of capture. The result period plots the probabilities of nesting according to period. If category is left to NA, the compound value for all the population is plotted. When result="data" is used, this is a parser for plot.TableECFOCF(). See this function for the parameters. The parameter y.axis is the shift of the x legends for result="prob".

Usage

# S3 method for ECFOCF
plot(x, ..., result = "CF", category = NA,
  period = 1)

Arguments

x

A result for fitCF().

...

Graphic parameters, see plot.TableECFOCF() or par.

result

What result will be plotted: data, dataOCF, dataECF, ECF, OCF, ECFOCF, ECFOCF0, CF, Prob, period

category

What category will be plotted, numeric or NA for all.

period

The period that will be plotted.

Value

Nothing

Details

plot.ECFOCF plots a result of clutch frequency fit.

See Also

Other Model of Clutch Frequency: ECFOCF_f, TableECFOCF, fitCF, lnLCF, logLik.ECFOCF, plot.TableECFOCF

Examples

Run this code
# NOT RUN {
library(phenology)
# Example
data(MarineTurtles_2002)
ECFOCF_2002 <- TableECFOCF(MarineTurtles_2002)
o_mu1p2_NB <- fitCF(x = c(mu = 4.6426989650675701, 
                         sd = 75.828239144717074, 
                         p1 = 0.62036295627161053,
                         p2 = -2.3923021862881511, 
                         OTN = 0.33107456308054345),
                 data=ECFOCF_2002)
                 
par(mar=c(4, 4, 1, 1)+0.4)
plot(o_mu1p2_NB, result="data", category=NA, 
     bty="n", las=1, cex.points=3, cex.axis = 0.8)
plot(o_mu1p2_NB,result="data", category=NA, 
     bty="n", las=1, cex.points=3, pch=NA, 
     col.labels = "red", show.labels=TRUE, cex.0=0.2, 
     show.0 = TRUE, col.0="blue", pch.0=4)
plot(o_mu1p2_NB, result="dataOCF", category=NA, 
     bty="n", las=1)
plot(o_mu1p2_NB, result="dataECF", category=NA, 
     bty="n", las=1)
     
plot(o_mu1p2_NB, result="CF", bty="n", las=1)

plot(o_mu1p2_NB, result="OCF", category=1, bty="n", las=1)
plot(o_mu1p2_NB, result="OCF", category=2, bty="n", las=1)

plot(o_mu1p2_NB, result="ECFOCF", bty="n", las=1)

plot(o_mu1p2_NB, result="ECFOCF0", bty="n", las=1)
plot(o_mu1p2_NB, result="ECFOCF0", category=1, bty="n", las=1)
plot(o_mu1p2_NB, result="ECFOCF0", category=2, bty="n", las=1)

plot(o_mu1p2_NB, result="Prob", category=c(1, 2), bty="n", las=1)
plot(o_mu1p2_NB, result="Prob", category=c(2, 1), bty="n", las=1)

# }

Run the code above in your browser using DataLab