Dynesty

Documentation for Dynesty.

Dynesty.dyplotConstant
`dyplot`

Object that holds the plotting submodule of the dynesty package

source
Dynesty.DynamicNestedSamplerType
`DynamicNestedSampler`

Julia interface to the dynesty DynamicNestedSampler class. Note that we do not pass the loglikelihood or prior transform function here. Instead this is passed to the dysample call.

Example

# define a distribution
d = MvNormal(ones(10))

loglikelihood(x) = logpdf(d, x)

prior_transform(p) = -10.0 .+ 20.0.*p

smplr = DynamicNestedSampler()

# sample using dynamic nested sampling with 500 initial live points
res = sample(loglikelihood, prior_transform, 10, smplr; dlogz=0.5, nlive_init=500)
source
Dynesty.DynestyOutputType
DynestyOutput

A objects that holds the dynesty output as well as the sampler. This object can be passed to the plotting functions to produce the usual dynesty diagnostic plots.

Notes

We have also implemented a limited number of Julia's Dictionary interface so you can access the output in the usual Dynesty manner

Example

# define a distribution
d = MvNormal(ones(10))

loglikelihood(x) = logpdf(d, x)

# We only look at finite region of parameter space
prior_transform(p) = -5.0 .+ 10.0.*p

smplr = NestedSampler()

# sample using dynamic nested sampling with 500 initial live points
res = dysample(loglikelihood, prior_transform, 10, smplr; dlogz=0.5, nlive_init=500)

# fetch the samples
res[:samples]

# print the keys
keys(res)
source
Dynesty.NestedSamplerType
`NestedSampler`

Julia interface to the dynesty NestedSampler class. Note that we do not pass the loglikelihood or prior transform function here. Instead this is passed to the dysample call.

Example

# define a distribution
d = MvNormal(ones(10))

loglikelihood(x) = logpdf(d, x)

prior_transform(p) = -10.0 .+ 20.0.*p

smplr = NestedSampler()

res = sample(loglikelihood, prior_transform, 10, smplr; dlogz=0.5)
source
Base.mergeMethod
merge(args::DynestyOutput...; print_progres=true)

Runs dynesty's merge_runs to combine multiple separate dynesty runs.

source
Dynesty.boundplotMethod
boundplot(d::DynestyOutput; kwargs...)

Produces the boundplot plot from the dynesty.plotting module. For a list of possible kwargs see the dynesty documentation at [dynesty.readthedocs.io]

source
Dynesty.cornerboundMethod
cornerbound(d::DynestyOutput; kwargs...)

Produces the cornerbound plot from the dynesty.plotting module. For a list of possible kwargs see the dynesty documentation at [dynesty.readthedocs.io]

source
Dynesty.cornerplotMethod
cornerplot(d::DynestyOutput; kwargs...)

Produces the cornerplot plot from the dynesty.plotting module. For a list of possible kwargs see the dynesty documentation at [dynesty.readthedocs.io]

source
Dynesty.cornerpointsMethod
cornerpoints(d::DynestyOutput; kwargs...)

Produces the cornerpoints plot from the dynesty.plotting module. For a list of possible kwargs see the dynesty documentation at [dynesty.readthedocs.io]

source
Dynesty.dysampleMethod
`dysample(loglikelihood, prior_transform, ndim::Int, s::DynamicNestedSampler; kwargs...)`

Runs dynesty's DynamicNestedSampler algorithm with the specified loglikelihood and priortransform. The loglikelihood and priortransform are functions. For the specific relevant kwargs see the dynesty documentation at [https://dynesty.readthedocs.io/]

source
Dynesty.dysampleMethod
`sample(loglikelihood, prior_transform, ndim::Int, s::NestedSampler; kwargs...)`

Runs dynesty's NestedSampler algorithm with the specified loglikelihood and priortransform. The loglikelihood and priortransform are functions. For the specific relevant kwargs see the dynesty documentation at [https://dynesty.readthedocs.io/]

source
Dynesty.resample_equalMethod
resample_equal(res::DynestyOutput, nsamples::Int)

Resample the dynesty nested sampling run so that the samples have equal weighting. This uses the StatsBase algorithm under the hood.

The results are a vector of vectors where the inner vector corresponds to the samples.

source
Dynesty.runplotMethod
runplot(d::DynestyOutput; kwargs...)

Produces the runplot plot from the dynesty.plotting module. For a list of possible kwargs see the dynesty documentation at [dynesty.readthedocs.io]

source
Dynesty.traceplotMethod
traceplot(d::DynestyOutput; kwargs...)

Produces the traceplot plot from the dynesty.plotting module. For a list of possible kwargs see the dynesty documentation at [dynesty.readthedocs.io]

source