update_according_to_ess_value: Calculate sum of weight matrix for active locations

View source: R/AMIS_steps.R

update_according_to_ess_valueR Documentation

Calculate sum of weight matrix for active locations

Description

This function sums the rows of the weight matrix weight_matrix for which the effective sample size ESS is below a target size target_size.

Usage

update_according_to_ess_value(weight_matrix, ess, target_size, log)

Arguments

weight_matrix

The weight_matrix as returned by compute_weight_matrix

ess

The effective sample size vector as returned by calculate_ess

target_size

A number representing the target size for the sample.

log

A logical indicating if the weights are logged.

Value

Vector containing the row sums of the active columns of the weight matrix.


OxfordRSE/trachomAMIS documentation built on Aug. 1, 2022, 10:21 p.m.