gadgetFileIO: Old style gadget file input and output (mostly deprecated)

read.gadget.likelihoodR Documentation

Old style gadget file input and output (mostly deprecated)

Description

read.gadget.likelihood reads the likelihood (input) file for gadget. The format of the likelihood file is described in gadget's user manual.

read.gadget.data reads data used by the various components

read.gadget.wgts reads the output from iterative weighting likelihood output

read.gadget.grouping reads the the likelihood grouping from the WGTS folder

Usage

read.gadget.likelihood(files = "likelihood")

write.gadget.likelihood(
  lik,
  file = "likelihood",
  data.folder = NULL,
  bs.sample = NULL
)

get.gadget.likelihood(likelihood, comp, inverse = FALSE)

read.gadget.main(file = "main")

write.gadget.main(main, file = "main")

clear.spaces(text)

read.gadget.data(likelihood, debug = FALSE, year_range = NULL)

strip.comments(file = "main")

read.gadget.wgts(
  params.file = "params.in",
  wgts = "WGTS",
  likelihood = "likelihood",
  lik.pre = "lik.",
  params.pre = "params.",
  parallel = FALSE
)

read.gadget.grouping(lik = read.gadget.likelihood(), wgts = "WGTS")

Arguments

files

a vector of character strings containing the names of the likelihood files

lik

old style gadget likelihood object

file

location of the gadget input file

data.folder

location of data folder (if changed)

bs.sample

(for bootstrap), appends the appropriate replicate number to data file

likelihood

likelihood file

comp

selected likelihood components

inverse

(logical) should inverse selection be applied

main

gadget.main object

text

string

debug

should debug information be printed

year_range

limit the years read in

params.file

base parameter file

wgts

logcation of the WGTS folder

lik.pre

strings matching the likelihood output

params.pre

strings matching the parameter estimates

parallel

should the files be read in parallel

Value

object of class gadget.likelihood, i.e. a list containing the various likelihood components

character string corresponding to the likelihood file (if desired)

likelihood object

object of class gadget.main

text of the main file (if desired)

list or matrix containing the (non-empty) values from the string

list of dataframes and degress of freedom

list containing the lines from the file stripped of unwanted text.

data.frame with parameter estimates and likelihood output from the iterative reweighting folder.

list of wgts groupings

Author(s)

Bjarki Þór Elvarsson

Bjarki Þór Elvarsson

Bjarki Thor Elvarsson

Bjarki Þór Elvarsson

Bjarki Þór Elvarsson

Bjarki Þór Elvarsson

Bjarki Þór Elvarsson

Bjarki Thor Elvarsson


Hafro/rgadget documentation built on July 21, 2022, 8:38 a.m.