plotAPDcorr: Plot APDcorr Posterior Samples and Predicted Effects

Description Usage Arguments Value Examples

Description

Plot histogram of posterior distribution samples and/or predicted effects of parameter estimated from APDREcorr function

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
plotAPDcorr(
  model,
  hist = TRUE,
  effects = TRUE,
  histcol = c("cyan4", "cyan4", "cyan4", "cyan4"),
  linecol = "red",
  effectcol = c("cyan4", "cyan4", "cyan4", "cyan4"),
  yname = "Focal",
  xname = c("C1", "C2", "C3", "C4")
)

Arguments

model

Object of class APD of model output from APDREcorr function

hist

Logical argument for whether to plot histogram of posterior distribution samples; default=TRUE

effects

Logical argument for whether to plot predicted effects; default=TRUE

histcol

Colour for posterior distribution histogram

linecol

Colour for 95% HDI line on posterior distribution histogram

effectcol

Colour for 95% HDI ribbon in line plot of predicted effects

yname

Character vector of name of focal, to be used in the y axis labels

xname

Character vector of name(s) of contingent(s), to be used in the x axis labels

Value

Histogram plot(s) of samples from posterior distribution for estimated relationship between focal and contingent(s), if plothist=TRUE

Plot of predicted effects (mean and 95% highest density interval) for relationship between focal APD and contingent(s) APD, if ploteffects=TRUE

Examples

1
2
3
4
5
data(wolfexample)
data(boarexample)
 WolfBoarAPDc<-APDREcorr(focal=wolfexample$Radians, cont1=boarexample$Radians,
    RE1=wolfexample$SamplingPeriod)
    plotAPDcorr(WolfBoarAPDc, yname="Wolf", xname="Boar") 

AnimalAPD documentation built on March 18, 2021, 5:07 p.m.