Robert Thomas Leaf, Ph.D.
I have developed a package of R functions to more easily and consistently plot the output from one or many .rdat files in a directory. The .rdat files are created by the ASPIC program from .inp files. The motivation for creating the aspic.plot package was to create a flexible suite of plotting routines that could handle the variable nature of .rdat files. For example, a routine that would scan the headers and extract tabular data regardless of how many indices or data sources are used in a model. I encourage users to download and customize the scripts as necessary – or use them freely for their own purposes.
Links are provided at the end of this page for downloading the ASPIC.PLOT suite of functions and ASPIC.
“aspic.plot” is a suite of functions to plot .rdat files created by the NOAA Fisheries Toolbox program "ASPIC," a commonly used program in fishery science and stock assessment. The package contains a number of plotting functions, an extraction and aggregation function, and an R analog to Matlab's “strncmpi” which is used by the various plotting functions.
The foundation of the code is the function ASPIC_rdata_input. This function scans the .rdat files in the current directory and asks the user which he would like to process. The function has no arguments and returns a list containing the extracted data from the .rdat files.
- ASPIC - A Stock Production Model Incorporating Covariates, The ASPIC model is part of the NOAA Fisheries Toolbox
- ASPIC.PLOT.tar - Suite of functions to plot .rdat files in ASPIC, developed by Dr. Robert Leaf, Gulf Coast Research Laboratory. The file is a .tar archive. (Left click to open the file; right click to download and save it.)
A function that scans the .rdat files from multiple or singule ASPIC model runs and creates a scatterplot matrix.
The correlation matrix plotting function models derived and input data in a pairwise fashion. The user is asked to pick a single value for index.1 and index.2 using the GUI. Press okay when finished. The x- and y-labels should match the chosen indices.
Plot_Individual_Indices("Annual F / FMSY","Landings",T)
This function plots the residuals using a 'histogram' like (or 'high-density') vertical lines.
Function creates a two panel plot of the stock and fishery status from multiple .rdat files.
This function plots the observed index values and the modeled (expected) values.
Plots the fishery and stock status estimated from an ASPIC model run in the same panel.