API
This page is a dump of all the docstrings found in the code.
OptimalPolicies.ULogPotential
— TypeULogPotential
ULogPotential holds the temperature parameter beta
in the objective function
OptimalPolicies.UMetropolis
— TypeUMetropolis
MCMC explorer, should not contain state that is replica-specific and/or changed in the inner sampling loop (use an Augmentation if the explorer needs replica-specific auxiliary state information)
OptimalPolicies.UState
— TypeUState
UState holds the state of the system, which is going to be application-specific. Here, it's just a number, but this might be itself a large object, e.g. a Matrix, or a lists of lists, etc.
OptimalPolicies.U
— MethodU(gam::Number, x::Number)
The potential function for some given potential barrier height gam
OptimalPolicies.chain
— Methodchain(target; tune = 0.1, init = 1.0, iters = Int(1e3))
The Metropolis algorithm targeting a particular potential function target
OptimalPolicies.chains
— Methodchains(; pot = U, tune = 0.1, init = 1.0, iters = Int(1e3), temps = [1, 2])
Generates chains based on the temps
OptimalPolicies.curried
— Methodcurried(gam::Number)
Returns a potential function for the given potential barrier height gam
OptimalPolicies.density
— Methoddensity(gam::Number, x::Number)
The density function for some given potential barrier height gam
OptimalPolicies.plot_chain
— Methodplot_chain(xvec, gam; dir = "result/")
Plot the value, autocorrelation, and density of a chain xvec
given the value of gam
, store the plot in the directory dir
OptimalPolicies.print_summary
— Methodprint_summary(mat, temps)
Computes and displays the statistics of the given matrix mat
Pigeons.step!
— MethodPigeons.step!(explorer::UMetropolis, replica, shared)
Customized MCMC exploration function that performs MCMC update within each chain
glossary:
explorer: object that does this updating
replica: roughly corresponds to a chain, which holds the state of the system, random number generator state, and some global parameters
shared: even higher level object that knows about other replicas