Skip to content

Commit 5189c38

Browse files
committed
Add docstring
1 parent 13e1228 commit 5189c38

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/mh-core.jl

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,17 @@ The sampler is constructed using
2929
```julia
3030
spl = MetropolisHastings(proposal)
3131
```
32+
33+
When using `MetropolisHastings` with the function `sample`, the following keyword
34+
arguments are allowed:
35+
36+
- `init_params` defines the initial parameterization for your model. If
37+
none is given, the initial parameters will be drawn from the sampler's proposals.
38+
- `param_names` is a vector of strings to be assigned to parameters. This is only
39+
used if `chain_type=Chains`.
40+
- `chain_type` is the type of chain you would like returned to you. Supported
41+
types are `chain_type=Chains` if `MCMCChains` is imported, or
42+
`chain_type=StructArray` if `StructArrays` is imported.
3243
"""
3344
mutable struct MetropolisHastings{D} <: Metropolis
3445
proposal :: D

0 commit comments

Comments
 (0)