Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
How to use NS
Create an XML file in BEAUti with an MCMC analysis
Open the XML file in a text editor
Replace the <run line that says something like
< run id="mcmc" spec="MCMC" chainLength="100000000">
<run id="mcmc" spec="beast.gss.NS" chainLength="20000" particleCount="1" subChainLength="5000" epsilon="1e-12">
- particleCount = number of particles (also known as active points).
- subChainLength = length of MCMC chain used to generate a new point.
- chainLength = maximum number of newly generated points.
- epsilon = used in stopping criterion. Lower means longer time to stop.
Save the XML and you should be able to run with BEAST. The estimates for marginal likelihood and standard deviation will be printed on the screen output.
Multi threaded nested sampling
<run id="mcmc" spec="beast.gss.MultiThreadedNS" threads="4" chainLength="20000" particleCount="1" subChainLength="5000" epsilon="1e-12">
Apart from the parameters for nested sampling, there is a "threads" attribute that allow you to specify the number of threads. All other parameters apply to each individual thread, so with 4 threads and 1 particles there are a total of 4 particles.
If you are interested in the posterior samples, you need an "NSLogger" for the tracelog. For this, you replace
<logger id="tracelog" ...
<logger id="tracelog" spec="NSLogger" ...
To post-process the file and get estimates for quantities of interest, you can use the NSLogAnalyser. The easiest way to start the analyser is by starting BEAUti, select menu File/Launch Apps, and a window pops up where you can choose the "NSLogAnalyser" icon to launch.