Learn R Programming

⚠️There's a newer version (1.3.0) of this package.Take me there.

UNIX

One can specify the path to where the Eigen header files are located and also whether to link common C++ files into every DSO/DLL we create or whether to treat the files as an extra library with:

R CMD INSTALL --configure-args='--with-eigen=/home/duncan/local --enable-lib' nimble

or, within R

install.packages("nimble", configure.args = c("--with-eigen=/home/duncan/local", "--enable-lib=true"), repos = NULL)

Windows

Typically, you need the R developer tools (i.e., compiler, make, etc.) to use nimble. Accordingly, it is quite straightforward to install the package from source as you will have the necessary tools already installed. These are available from the Rtools page on CRAN.

To install the package from source, from within R,

install.packages("nimble", type = "source", INSTALL_opts = "--merge-multiarch")

or from a local copy of the source package,

install.packages("nimble_0.6-2.tar.gz", repos = NULL, INSTALL_opts = "--merge-multiarch")

Alternatively, use the shell command (in the DOS Command prompt)

R CMD INSTALL --merge-multiarch nimble_0.6-9.tar.gz

Of course, you can also compile directly from a clone of the git repository:

R CMD INSTALL --merge-multiarch nimble

The --merge-multiarch is necessary when using a version of R that supports both 32 and 64 bit. This option to installation will ensure that create both 32 and 64 bit installations.

Creating a Windows Binary

R CMD build nimble
R CMD INSTALL --build --merge-multiarch nimble_0.6-9.tar.gz

We need to create the .tar.gz file first, hence the first command.

Copy Link

Version

Install

install.packages('nimble')

Monthly Downloads

3,433

Version

0.11.0

License

BSD_3_clause + file LICENSE | GPL (>= 2)

Issues

Pull Requests

Stars

Forks

Maintainer

Christopher Paciorek

Last Published

April 17th, 2021

Functions in nimble (0.11.0)

BUGSdeclClass-class

BUGSdeclClass contains the information extracted from one BUGS declaration
Constraint

Constraint calculations in NIMBLE
CmodelBaseClass-class

Class CmodelBaseClass
CnimbleFunctionBase-class

Class CnimbleFunctionBase
Categorical

The Categorical Distribution
ChineseRestaurantProcess

The Chinese Restaurant Process Distribution
ADNimbleList

CAR_calcNumIslands

Calculate number of islands based on a CAR adjacency matrix.
CAR-Normal

The CAR-Normal Distribution
CAR-Proper

The CAR-Proper Distribution
MCMCconf-class

Class MCMCconf
Inverse-Wishart

The Inverse Wishart Distribution
MultivariateNormal

The Multivariate Normal Distribution
Inverse-Gamma

The Inverse Gamma Distribution
as.carCM

Convert weights vector to parameters of dcar_proper distributio
as.carAdjacency

Convert CAR structural parameters to adjacency, weights, num format
Dirichlet

The Dirichlet Distribution
asRow

Turn a numeric vector into a single-row or single-column matrix
Double-Exponential

The Double Exponential (Laplace) Distribution
autoBlock

Automated parameter blocking procedure for efficient MCMC sampling
buildBootstrapFilter

Placeholder for buildBootstrapFilter
Multivariate-t

The Multivariate t Distribution
buildAuxiliaryFilter

Placeholder for buildAuxiliaryFilter
Multinomial

The Multinomial Distribution
Exponential

The Exponential Distribution
Rmatrix2mvOneVar

Set values of one variable of a modelValues object from an R matrix
buildEnsembleKF

Placeholder for buildEnsembleKF
buildIteratedFilter2

Placeholder for buildIteratedFilter2
decideAndJump

Creates a nimbleFunction for executing the Metropolis-Hastings jumping decision, and updating values in the model, or in a carbon copy modelValues object, accordingly.
decide

Makes the Metropolis-Hastings acceptance decision, based upon the input (log) Metropolis-Hastings ratio
MCMCsuite

Placeholder for MCMCsuite
carMinBound

Calculate the lower bound for the autocorrelation parameter of the dcar_proper distribution
carMaxBound

Calculate the upper bound for the autocorrelation parameter of the dcar_proper distribution
compareMCMCs

Placeholder for compareMCMCs
distributionInfo

Get information about a distribution
configureRJ

Configure Reversible Jump for Variable Selection
configureMCMC

Build the MCMCconf object for construction of an MCMC object
checkInterrupt

Check for interrupt (e.g. Ctrl-C) during nimbleFunction execution. Part of the NIMBLE language.
getNimbleOption

Get NIMBLE Option
codeBlockClass-class

Class codeBlockClass
getParam

Get value of a parameter of a stochastic node in a model
RmodelBaseClass-class

Class RmodelBaseClass
identityMatrix

Create an Identity matrix (Deprecated)
initializeModel

Performs initialization of nimble model node values and log probabilities
eigenNimbleList

eigenNimbleList definition
modelValues

Create a NIMBLE modelValues Object
flat

The Improper Uniform Distribution
buildMCMC

Create an MCMC function from a NIMBLE model, or an MCMC configuration object
modelInitialization

Information on initial values in a NIMBLE model
StickBreakingFunction

The Stick Breaking Function
extractControlElement

Extract named elements from MCMC sampler control list
carBounds

Calculate bounds for the autocorrelation parameter of the dcar_proper distribution
getConditionallyIndependentSets

Get a list of conditionally independent sets of nodes in a nimble model
nimNumeric

Creates numeric, integer or logical vectors for use in nimbleFunctions
nimMatrix

Creates matrix or array objects for use in nimbleFunctions
getDefinition

Get nimbleFunction definition
is.nf

check if a nimbleFunction
Interval

Interval calculations
model_macro_builder

EXPERIMENTAL: Turn a function into a model macro builder A model macro expands one line of code in a nimbleModel into one or more new lines. This supports compact programming by defining re-usable modules. model_macro_builder takes as input a function that constructs new lines of model code from the original line of code. It returns a function suitable for internal use by nimbleModel that arranges arguments for input function. Macros are an experimental feature and are available only after setting nimbleOptions(enableModelMacros = TRUE).
getBUGSexampleDir

Get the directory path to one of the classic BUGS examples installed with NIMBLE package
is.nl

check if a nimbleList
getBound

Get value of bound of a stochastic node in a model
nimbleCode

Turn BUGS model code into an object for use in nimbleModel or readBUGSmodel
compileNimble

compile NIMBLE models and nimbleFunctions
nodeFunctions

calculate, calculateDiff, simulate, or get the current log probabilities (densities) a set of nodes in a NIMBLE model
nimble

nimble
nimbleType-class

create a nimbleType object
nfMethod

access (call) a member function of a nimbleFunction
Wishart

The Wishart Distribution
nimDim

return sizes of an object whether it is a vector, matrix or array
any_na

Determine if any values in a vector are NA or NaN
buildMCEM

Builds an MCEM algorithm from a given NIMBLE model
modelBaseClass-class

Class modelBaseClass
buildLiuWestFilter

Placeholder for buildLiuWestFilter
declare

Explicitly declare a variable in run-time code of a nimbleFunction
makeBoundInfo

Make an object of information about a model-bound pairing for getBound. Used internally
nimCopy

Copying function for NIMBLE
nimEigen

Spectral Decomposition of a Matrix
deregisterDistributions

Remove user-supplied distributions from use in NIMBLE BUGS models
makeParamInfo

Make an object of information about a model-parameter pairing for getParam. Used internally
setAndCalculate

Creates a nimbleFunction for setting the values of one or more model nodes, calculating the associated deterministic dependents and logProb values, and returning the total sum log-probability.
setAndCalculateOne

Creates a nimbleFunction for setting the value of a scalar model node, calculating the associated deterministic dependents and logProb values, and returning the total sum log-probability.
nimDerivs

Nimble Derivatives
nimbleList

create a nimbleList
modelDefClass-class

Class for NIMBLE model definition
nimbleFunctionVirtual

create a virtual nimbleFunction, a base class for other nimbleFunctions
setSize

set the size of a numeric variable in NIMBLE
rankSample

Generates a weighted sample (with replacement) of ranks
setupOutputs

Explicitly declare objects created in setup code to be preserved and compiled as member data
readBUGSmodel

Create a NIMBLE BUGS model from a variety of input formats, including BUGS model files
nimble-R-functions

NIMBLE language functions for R-like vector construction
nimbleRcall

Make an R function callable from compiled nimbleFunctions (including nimbleModels).
nimSvd

Singular Value Decomposition of a Matrix
nimbleOptions

NIMBLE Options Settings
runMCMC

Run one or more chains of an MCMC algorithm and return samples, summary and/or WAIC
getSamplesDPmeasure

Get posterior samples for a Dirichlet process measure
svdNimbleList

svdNimbleList definition
withNimbleOptions

Temporarily set some NIMBLE options.
singleVarAccessClass-class

Class singleVarAccessClass
nimStop

Halt execution of a nimbleFunction function method. Part of the NIMBLE language
nimCat

cat function for use in nimbleFunctions
nimbleFunction

create a nimbleFunction
nfVar

Access or set a member variable of a nimbleFunction
nimPrint

print function for use in nimbleFunctions
nimbleExternalCall

Create a nimbleFunction that wraps a call to external compiled code
optimResultNimbleList

getsize

Returns number of rows of modelValues
modelValuesBaseClass-class

Class modelValuesBaseClass
nimble-internal

Functions and Classes Internal to NIMBLE
sampler_BASE

MCMC Sampling Algorithms
nimbleFunctionBase-class

Class nimbleFunctionBase
nimOptim

optimControlNimbleList

nimOptimDefaultControl

nimbleFunctionList-class

Create a list of nimbleFunctions
modelValuesConf

Create the confs for a custom NIMBLE modelValues object
optimDefaultControl

printErrors

Print error messages after failed compilation
nimble-math

Mathematical functions for BUGS and nimbleFunction programming
nimbleMCMC

Executes one or more chains of NIMBLE's default MCMC algorithm, for a model specified using BUGS code
nimbleModel

Create a NIMBLE model from BUGS code
t

The t Distribution
testBUGSmodel

Tests BUGS examples in the NIMBLE system
run.time

Time execution of NIMBLE code
runCrossValidate

Perform k-fold cross-validation on a NIMBLE model fit by MCMC
valueInCompiledNimbleFunction

get or set value of member data from a compiled nimbleFunction using a multi-interface
values

Access or set values for a set of nodes in a model
simNodesMV

Basic nimbleFunctions for using a NIMBLE model with sets of stored values
resize

Resizes a modelValues object
simNodes

Basic nimbleFunctions for calculate, simulate, and getLogProb with a set of nodes
registerDistributions

Add user-supplied distributions for use in NIMBLE BUGS models