AddNames: Add Names

Description Usage Arguments Examples

Description

Add names to columns from naming list

Usage

1
2
AddNames(par, job.names, job.group = NULL, keep.par = TRUE,
  names.only = FALSE, ...)

Arguments

par

defined parameter to analyze (e.g., "cor[1,2]")

job.names

names of all parameters in analysis, Default: NULL

job.group

for some hierarchical models with several layers of parameter names (e.g., latent and observed parameters), Default: NULL

keep.par

logical, indicating whether or not to keep parameter name (e.g., "cor[1,2]"), Default: TRUE

names.only

logical, indicating whether or not to return vector (TRUE) or string with separator (e.g., "cor[1,2]: A vs. B"), Default: FALSE

...

further arguments passed to or from other methods

Examples

1
2
3
4
5
6
7
8
par <- "cor[1,2]"
job.names <- c("A","B")
AddNames(par, job.names, keep.par = TRUE)
# [1]  "cor[1,2]: A vs. B"
AddNames(par, job.names, keep.par = FALSE)
# [1]  "A vs. B"
AddNames(par, job.names, names.only = TRUE)
# [1]  "A" "B"

bfw documentation built on May 2, 2019, 6:51 a.m.