plot_residuals: Plot Pearson residuals on map

View source: R/deprecated.R

plot_residualsR Documentation

Plot Pearson residuals on map

Description

plot_residuals shows average Pearson residual for every knot for encounter probability and positive catch rate components

Usage

plot_residuals(
  Lat_i,
  Lon_i,
  TmbData,
  Report,
  Q,
  projargs = "+proj=longlat",
  working_dir = paste0(getwd(), "/"),
  spatial_list,
  extrapolation_list,
  Year_Set = NULL,
  Years2Include = NULL,
  zrange,
  ...
)

Arguments

Lat_i

Latitude for every observation i

Lon_i

Longitude for every observation i

TmbData

a tagged list of data inputs generated by make_data

Report

tagged list of outputs from TMB model via Obj$report()

Q

Output from QQ_Fn

projargs

Character passed to CRS and see that documentation for description. See https://proj.org/operations/projections/index.html for a list of projections to pass via projargs. As a stable default please consider projargs='+proj=natearth +lon_0=0 +units=km' where argument +lon_0 allows the user to center eastings on a specified longitude.

zrange

lower and upper bounds for plotted value of Pearson residuals, used to change plotting scale to eliminate influence of outliers on plotting scale

...

arguments passed to FisshStatsUtils::plot_variable

savdir

directory to use when saving results

Value

A tagged list of Pearson residuals

Q1_xt

Matrix of average residuals for encounter/non-encounter component by site x and year t

Q2_xt

Matrix of average residuals for positive-catch-rate component by site x and year t


James-Thorson/FishStatsUtils documentation built on Feb. 6, 2024, 4:26 a.m.