impactplot: impactplot - Plots relative contribution to CPUE trend of...

Description Usage Arguments Value Examples

View source: R/cpueplots.R

Description

Calculates and plots out the contribution to a standardized CPUE trend of each of the factors included in the standardization. The number on each graph is the sum of squared differences between the previous model and the current model - as a measure of the relative effect of the factor concerned. Positive effects are shown as blue bars, negative effects are shown as red bars.

Usage

1
impactplot(inout, mult = 3, FY = FALSE)

Arguments

inout

is the list output from the standLM function containing the standardization

mult

default value is 3 - it is used to scale the bars on the plot.

FY

- are the years fishing seasons or calender years; defaults to FALSE, which assumes calendar years for the x-axis.

Value

generates a plot of the impact of each factor on the CPUE trend, in addition, the function returns, invisibly, two tables as a list, the first $result summarizes the impact of each factor included in the analysis, including the sum of absolute differences between each model and the one before it (the top plot is for the complete model). The second table $deviates lists the actual differences between the particular vaiables and the previous models.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
data(sps)
splabel = "Species"
sps$Year <- factor(sps$Year)
sps$Month <- factor(sps$Month)
sps$Vessel <- factor(sps$Vessel)
labelM <- c("Year","Vessel","Month")
mods <- makemodels(labelM)
out <- standLM(mods,sps,splabel)
impactplot(out,mult=3)

## End(Not run)

haddonm/r4cpue documentation built on May 11, 2020, 1:31 a.m.