https://github.com/anthofflab/robustadaptivemetropolissampler.jl

A Julia implementation of the RAM algorithm (Vihola, 2012)

https://github.com/anthofflab/robustadaptivemetropolissampler.jl

Science Score: 23.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
  • .zenodo.json file
  • DOI references
    Found 2 DOI reference(s) in README
  • Academic publication links
  • Committers with academic emails
    2 of 5 committers (40.0%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (12.3%) to scientific vocabulary

Keywords

julia mcmc

Keywords from Contributors

stochastic-processes differential-equations ode pde diffusion nonlinear-programming systems-biology workflow-engine computational-biology parameter-estimation
Last synced: 9 months ago · JSON representation

Repository

A Julia implementation of the RAM algorithm (Vihola, 2012)

Basic Info
  • Host: GitHub
  • Owner: anthofflab
  • License: mit
  • Language: Julia
  • Default Branch: master
  • Homepage:
  • Size: 52.7 KB
Statistics
  • Stars: 11
  • Watchers: 2
  • Forks: 2
  • Open Issues: 10
  • Releases: 0
Topics
julia mcmc
Created almost 7 years ago · Last pushed almost 4 years ago
Metadata Files
Readme Contributing License

README.md

RobustAdaptiveMetropolisSampler

Project Status: WIP – Initial development is in progress, but there has not yet been a stable, usable release suitable for the public. codecov

Overview

This package implements the robust adaptive metropolis (RAM) sampler described in Vihola (2012) for the Julia language.

Usage

The RAM_sample function runs a MCMC sampler on a given log target function. The arguments for the functions are as follows:

julia RAM_sample(logtarget, x0, M0, n; opt_α=0.234, γ=2/3, q=Normal(), show_progress=true)

  • logtarget this must be a callable that accepts one parameter which is a vector of values to evaluate the log target function on. The function passed must return the log value of the target function.
  • x0 is a vector of initial values at which the sampler will start the MCMC algorithm. The length of the vector controls the dimensionality of the problem.
  • M0 is the initial co-variance matrix that the sampler should use to scale the new proposal. M0 can be passed in many different ways: 1) a scalar: an isotropic covariance matrix with diagonal elements abs2(M0). 2) an AbstractVector: a diagonal covariance matrix with diagonal elements abs2.(M0). 3) an AbstractMatrix (or a Diagnoal or an AbstractPDMat): a value of any of these types will be interpreted directly as the covariance matrix.
  • n: the number of elements to be sampled, i.e. the length of the chain.
  • opt_α: the target acceptance rate the algorithm is trying to hit.
  • γ: a parameter for the computation of the step size sequence.
  • q: the proposal distribution.
  • show_progress: a flag that controls whether a progress bar is shown.
  • output_log_probability_x: a flag that controls whether to include output for the log-posterior scores from each Markov chain iteration.

The function returns a NamedTuple with three (or optionally four) elements: * chain: a Matrix with the result chain. Each row is one sample, the columns correspond to the dimensions of the problem. * acceptance_rate: the acceptance rate for the overall chain. * M: the last co-variance matrix used in the algorithm. * log_probabilities_x: the log-posterior score from each Markov chain iteration. Each element of log_probabilities_x corresponds to a row from chain.

A simple example of using the function is

```julia using Distributions, RobustAdaptiveMetropolisSampler

chain, accrate, S = RAMsample( p -> logpdf(Normal(3., 2), p[1]), # log target function [0.], # Initial value 0.5, # Use an isotropic covariance matrix with diagonal elements abs2(0.5) 100000 # Number of runs ) ```

Owner

  • Name: The Society, Environment and Economics Lab
  • Login: anthofflab
  • Kind: organization
  • Location: Berkeley, CA

Lab group headed by David Anthoff at the Energy and Resources Group, UC Berkeley

GitHub Events

Total
  • Watch event: 1
Last Year
  • Watch event: 1

Committers

Last synced: about 3 years ago

All Time
  • Total Commits: 71
  • Total Committers: 5
  • Avg Commits per committer: 14.2
  • Development Distribution Score (DDS): 0.113
Top Committers
Name Email Commits
David Anthoff a****f@b****u 63
Julia Package Butler 3
github-actions[bot] 4****]@u****m 2
Tony Wong a****a@c****u 2
CompatHelper Julia c****y@j****g 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 10 months ago

All Time
  • Total issues: 12
  • Total pull requests: 21
  • Average time to close issues: 20 days
  • Average time to close pull requests: about 1 month
  • Total issue authors: 7
  • Total pull request authors: 4
  • Average comments per issue: 0.92
  • Average comments per pull request: 0.33
  • Merged pull requests: 16
  • Bot issues: 0
  • Bot pull requests: 9
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • marouanehanhasse (3)
  • davidanthoff (3)
  • FrankErrickson (2)
  • dlakelan (1)
  • tonyewong (1)
  • arnab13061989 (1)
  • JuliaTagBot (1)
Pull Request Authors
  • davidanthoff (10)
  • github-actions[bot] (9)
  • waldie11 (1)
  • JuliaTagBot (1)
Top Labels
Issue Labels
enhancement (3)
Pull Request Labels
no changelog (3)

Packages

  • Total packages: 1
  • Total downloads:
    • julia 9 total
  • Total dependent packages: 1
  • Total dependent repositories: 0
  • Total versions: 5
juliahub.com: RobustAdaptiveMetropolisSampler

A Julia implementation of the RAM algorithm (Vihola, 2012)

  • Versions: 5
  • Dependent Packages: 1
  • Dependent Repositories: 0
  • Downloads: 9 Total
Rankings
Dependent repos count: 9.9%
Dependent packages count: 23.0%
Average: 26.0%
Forks count: 33.3%
Stargazers count: 37.7%
Last synced: 10 months ago