makeAD: Make an Executable Binary File from a C File

View source: R/PBSadmb.r

makeADR Documentation

Make an Executable Binary File from a C File

Description

Essentially a wrapper function that calls in sequence: convAD, compAD, and linkAD.

Usage

makeAD(prefix, raneff=FALSE, safe=TRUE, dll=FALSE, debug=FALSE, 
   logfile=TRUE, add=TRUE, verbose=TRUE, pathfile=NULL)

Arguments

prefix

string name prefix of the ADMB project (e.g., "vonb").

raneff

logical: use the random effects model, otherwise use the normal model.

safe

logical: if TRUE, use safe mode with bounds checking on all array objects, otherwise use optimized mode for fastest execution.

dll

create dll (rather than executable)

debug

compile with debug symbols

logfile

logical: if TRUE, create a log file of the messages from the shell call.

add

logical: if TRUE, append shell call messages to an exsiting log file.

verbose

logical: if TRUE, report the shell call an its messages to the R console.

pathfile

string name of 2-column text file that details the relevant paths for the R variables admbpath, gccpath, and editor.

Details

This function uses the C++ comiler declared in .PBSadmb. If logfile=TRUE, any errors will appear in 'prefix'.log. If verbose=TRUE, they will appear in the R console.

Value

Returns nothing. The three functions called by makeAD each return the shell call and its messages.

Note

A wrapper function that can be called from a GUI exists as .win.makeAD.

The optional pathfile is offered for use in command (non-GUI) functions. Users can easily create this file in a text editor. Note that on UNIX systems, only the admbpath (actually the path to ADMB's home directory) and text editor are used because the MinGW compiler (gccpath) and UNIX tools are already recognised.

Author(s)

Jon T. Schnute, Scientist Emeritus
Pacific Biological Station (PBS), Fisheries & Oceans Canada (DFO), Nanaimo BC
Last modified Rd: 2015-01-27

See Also

convAD, compAD, linkAD, runAD, readADpaths


PBSadmb documentation built on Nov. 11, 2023, 1:07 a.m.