org.omegahat.Simulation.MCMC
Class CustomMetropolisSampler

java.lang.Object
  |
  +--org.omegahat.Simulation.MCMC.NotifyingMCMCObject
        |
        +--org.omegahat.Simulation.MCMC.BaseMarkovChain
              |
              +--org.omegahat.Simulation.MCMC.CustomMarkovChain
                    |
                    +--org.omegahat.Simulation.MCMC.CustomMetropolisHastingsSampler
                          |
                          +--org.omegahat.Simulation.MCMC.CustomMetropolisSampler
All Implemented Interfaces:
MarkovChain, NotifyingObject, java.lang.Runnable

public class CustomMetropolisSampler
extends CustomMetropolisHastingsSampler

A Markov Sampler that uses an internal SymmetricProposal and UnnormalizedDensity to generate the next Markov state.


Inner classes inherited from class org.omegahat.Simulation.MCMC.CustomMarkovChain
CustomMarkovChain.listenerPrinter, CustomMarkovChain.NormalGenerator
 
Inner classes inherited from class org.omegahat.Simulation.MCMC.NotifyingMCMCObject
NotifyingMCMCObject.MyHandle
 
Fields inherited from class org.omegahat.Simulation.MCMC.CustomMetropolisHastingsSampler
accepted, current, debug, detailed, log_p_X, log_p_Y, log_q_X_to_Y, log_q_Y_to_X, logAcceptProb, numAccepted, numProposed, prng, proposal, proposed, target, uniformRand
 
Fields inherited from class org.omegahat.Simulation.MCMC.CustomMarkovChain
generator
 
Fields inherited from class org.omegahat.Simulation.MCMC.BaseMarkovChain
state
 
Fields inherited from class org.omegahat.Simulation.MCMC.NotifyingMCMCObject
listeners
 
Constructor Summary
CustomMetropolisSampler(ContainerState state, UnnormalizedDensity target, SymmetricProposal proposal, PRNG prng)
           
CustomMetropolisSampler(java.lang.Object state, UnnormalizedDensity target, SymmetricProposal proposal, PRNG prng)
           
 
Method Summary
protected  double acceptanceProb(java.lang.Object current, java.lang.Object proposed)
           
protected  double logAcceptanceProb(java.lang.Object current, java.lang.Object proposed)
           
static void main(java.lang.String[] argv)
           
 
Methods inherited from class org.omegahat.Simulation.MCMC.CustomMetropolisHastingsSampler
acceptanceRatio, accepted, arrayToString, current, detailed, detailed, generate, getPRNG, getProposal, getTarget, log_p_X, log_p_Y, log_q_X_to_Y, log_q_Y_to_X, logAcceptProb, numAccepted, numProposed, proposed, resetCounters, step, uniformRand
 
Methods inherited from class org.omegahat.Simulation.MCMC.BaseMarkovChain
getState, iterate, run
 
Methods inherited from class org.omegahat.Simulation.MCMC.NotifyingMCMCObject
notifyAll, registerListener, unregisterListener
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Constructor Detail

CustomMetropolisSampler

public CustomMetropolisSampler(ContainerState state,
                               UnnormalizedDensity target,
                               SymmetricProposal proposal,
                               PRNG prng)

CustomMetropolisSampler

public CustomMetropolisSampler(java.lang.Object state,
                               UnnormalizedDensity target,
                               SymmetricProposal proposal,
                               PRNG prng)
Method Detail

acceptanceProb

protected double acceptanceProb(java.lang.Object current,
                                java.lang.Object proposed)
Overrides:
acceptanceProb in class CustomMetropolisHastingsSampler

logAcceptanceProb

protected double logAcceptanceProb(java.lang.Object current,
                                   java.lang.Object proposed)
Overrides:
logAcceptanceProb in class CustomMetropolisHastingsSampler

main

public static void main(java.lang.String[] argv)