Description Usage Arguments Value Examples
View source: R/normalize_weight.R
Takes a vector of real values, and return the vector of normalized exponentiated values, as well as average of the exponentiated unnormalized values.
1 | normalize_weight(logweights)
|
logweights |
is a vector of n real values |
a vector of n non-negative values summing to one
1 2 3 4 | N <- 1000
logweights <- rnorm(N)
normalize_weight_results <- normalize_weight(logweights)
normalized_weights <- normalize_weight_results$nw
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.