Learn R Programming

NeuralEstimators (version 0.1.2)

estimate: estimate

Description

estimate parameters from observed data using a neural estimator

Usage

estimate(estimator, Z, theta = NULL, use_gpu = TRUE)

Value

a matrix of parameter estimates (i.e., estimator applied to Z)

Arguments

estimator

a neural estimator

Z

data; format should be amenable to the architecture of estimator

theta

parameter vectors (only for neural estimators that take both the data and parameters as input, e.g., neural ratio estimators)

use_gpu

a boolean indicating whether to use the GPU if it is available (default true)

Examples

Run this code
if (FALSE) {
library(NeuralEstimators)
library(JuliaConnectoR)

## Observed data: 100 replicates of a univariate random variable
Z <- matrix(rnorm(100), nrow = 1)

## Construct an (un-trained) point estimator
estimator <- initialise_estimator(1, architecture = "MLP")

## Apply the estimator
estimate(estimator, Z)
}

Run the code above in your browser using DataLab