stratisfy | R Documentation |
stratisfy is a program capable of Stratified Analyses of both DFO and NMFS fisheries survey data. This package attempts to emulate the results of the older, APL version which has been in use for many years.
Using stratisfy requires:
an Oracle account on the DFO PTRAN database;
access to PTRAN (i.e. either within the network, or via a VPN)
appropriate select permissions on the 'groundfish' and/or 'usnefsc' schemas
New Oracle accounts are requested by filling out a computer account request form. These forms may be obtained from IM&TS. Select access to the DFO and NMFS data is provided by the respective datasets manager (checking with Mike.McMahon@dfo-mpo.gc.ca is a good start).
Users can supply as much or as little information as they want when calling stratisfy(). If required information is not supplied, a select box will show the available options to the user. Please see below for examples of function calls providing both the minimum and the maximum number of parameters.
Fun Facts About stratisfy
Berried Females – APL stratisfy was inconsistent with species where females could be coded as 'berried' (i.e. 3). When unsexed analyses were done, the females were included, but when sexed analyses were done, these females were not included in the results. Such inconsistency seems suboptimal, and is retained for now such that APL and R versions of the application can be compared.
Ages By Sex – When APL stratisfy did analyses by sex, it combined the
sexes for the 'Age Mean', 'Age Total', (and standard errors of each). This
version adds the parameter ageBySex
so that by setting it to FALSE,
you can get the combined results, but you can also set it to TRUE, and get
the values for each sex individually.
I liked the old way – Some aspects of the 'classic' (i.e. APL)
stratisfy seemed inefficient. For example, the Strata information was broken
up over multiple worksheets, as was the weight information. By default, a new
spreadsheet has been designed, but since there will always be those who
prefer the old way, setting output='classic'
will generate a
spreadsheet almost indistinguishable from the APL version.
stratisfy(
usepkg = "rodbc",
agency = "DFO",
type = 1,
year = NULL,
season = NULL,
missions = NULL,
strataTable = NULL,
wingspread = 41,
towDist = 1.75,
strata = NULL,
areas = NULL,
spp = NULL,
bySex = NULL,
ageBySex = FALSE,
useBins = T,
output = "new",
alkTable = NULL,
file_id = NULL,
confirmMissions = TRUE,
fn.oracle.username = "_none_",
fn.oracle.password = "_none_",
fn.oracle.dsn = "_none_"
)
usepkg |
The default value is |
agency |
The default value is |
type |
This is the 'experiment type', and the default value is |
year |
The default value is |
season |
The default value is |
missions |
The default value is |
strataTable |
The default value is |
wingspread |
This is the width in feet of a standard tow. The default
value is |
towDist |
This is the length (NM) of a standard tow. The default value
is |
strata |
These are the strata for which you want results. The default
value is |
areas |
These are the areas for which you want results. Some strata
can be further broken down by areas, so this allows selection of data within
a part of a strata. It can also be set to |
spp |
This is the species code for the species you want to analyze.
The default value is |
bySex |
If the selected species was measured by sex, this parameter
allows you to perform calculations by sex. The default value is |
ageBySex |
The APL version of stratisfy ignored sex differences in some
age results (e.g. 'age by set', 'age mean', 'age total', ' etc.) despite
analyses being done by sex. The default value of this parameter is
|
useBins |
The default value is |
output |
The default value is |
alkTable |
The default is |
file_id |
This is a modifier you can have appended to the output
filename. The resultant file will be called |
confirmMissions |
The default is |
fn.oracle.username |
default is |
fn.oracle.password |
default is |
fn.oracle.dsn |
default is |
Reports of errors and/or recommendations for improvements should be addressed to: Mike McMahon (Mike.McMahon@dfo-mpo.gc.ca) Fisheries and Oceans Canada
Mike McMahon, Mike.McMahon@dfo-mpo.gc.ca
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.