Did you know ... Search Documentation:
Packs (add-ons) for SWI-Prolog

Package "bims"

Title:Bayesian inference of model structure.
Rating:Not rated. Create the first rating!
Latest version:2.2
SHA1 sum:52a1e0efb5e91208b8b38675dc3154b04edd43fb
Author:James Cussens http://www.cs.york.ac.uk/~jc
Nicos Angelopoulos http://stoics.org.uk/~nicos
Maintainer:Nicos Angelopoulos http://stoics.org.uk/~nicos
Packager:Nicos Angelopoulos http://stoics.org.uk/~nicos
Home page:http://stoics.org.uk/~nicos/sware/bims
Download URL:http://stoics.org.uk/~nicos/sware/packs/bims/bims-*.tgz
Requires:lib

Reviews

No reviews. Create the first review!.

Details by download location

VersionSHA1#DownloadsURL
0.6226a3c3f955f5101cf8f3f75ab326b6312c183d08http://stoics.org.uk/~nicos/sware/packs/bims/bims-0.6.tgz
1.154d2565187150656160b1dcaed6dad4b2339925c9http://stoics.org.uk/~nicos/sware/packs/bims/bims-1.1.tgz
2.0746110ff7e22f090d35254a61bd333e1777ab6a83http://stoics.org.uk/~nicos/sware/packs/bims/bims-2.0.tgz
2.19332c27bf7c7287b505be5cbcda568d4641ee8712http://www.stoics.org.uk/~nicos/sware/packs/bims/bims-2.1.tgz
2.252a1e0efb5e91208b8b38675dc3154b04edd43fb2http://stoics.org.uk/~nicos/sware/packs/bims/bims-2.2.tgz

Introduction

Bims (Bayesian inference over model structures) implements MCMC learning over statistical models defined in the Dlp (Distributional logic programming) probabilistic language.

Bims is released under the MIT licence.

Currently there are 2 model spaces supported:

  • Carts (Classification & Regression trees), and
  • Bayesian Networks

Additional model spaces can be easily implemented by defining new likelihood plug-ins and programming appropriate priors.

Examples provided

Carts examples

?- bims( [] ).
?- bims( [data(carts),models(carts),likelihood(carts)] ).

The above are two equivalent ways to run the Carts example provided.

This runs 3 chains each of length 100 on the default Carts data using the default likelihood. The default dataset is the breast cancer Winsconsin (BCW) data from the machine learning repository. There are 2 categories, 9 variables and 683 data points in this dataset. You can view the data with

?- edit( pack(bims/data/carts) ).

The default likelihood is an implementation of the classification likelihood function presented in: H Chipman, E George, and R McCulloch. Bayesian CART model search (with discussion). J. of the American Statistical Association, 93:935–960, 1998.

Bns examples

?- bims( [models(bns)] ).
?- bims( [data(bns),models(bns),likelihood(bns)] ).

The above are two equivalent ways to run the Bns example provided.

This runs 3 chains each of length 100 on the default bns data using default likelihood. The dataset is a sampled dataset from the ASIA network and it comprises of 8 variables and 2295 datapoints. You can view the data with

?- edit( pack(bims/data/bns) ).

The default BN likelihood is an instance of the BDeu metric for scoring BN structures.

W. L. Buntine. Theory refinement of Bayesian networks. In Bruce D’Ambrosio, Philippe Smets, and Piero Bonissone, editors, Proceedings of the Seventh Annual Conference on Uncertainty in Artificial Intelligence (UAI–1991), pages 52–60, 1991

David Heckerman, Dan Geiger, and David M. Chickering. Learning Bayesian networks: The combination of knowledge and statistical data. Machine Learning, 20(3):197–243, 1995.

Learning models from new datasets

An easy way to run Bims on your data is to create a new directory and within that sub-directory data/. Copy your data there and pass options data/1 to the basename of the data file.

For example, assuming your data are in data/bcw.pl

?- bims( [models(carts),data(bcw)] ).

Learning new statistical models.

To learn new statistical models create a subdirectory within models/ with new model name and place within there directories lklhoods and dlps containing code implementing the likelihood and prior progrms respectively.

See models/carts and models/bns for examples.

Pack info

author
- Nicos Angelopoulos, http://stoics.org.uk/~nicos
- James Cussens (University of York), http://cs.york.ac.uk/~jc
version
- 2.2.0 2017/4/18
See also
- http://stoics.org.uk/~nicos/sware/bims
license
- MIT
To be done
- bims_default(-Def).
- test on Windows (and Mac ?)

Contents of pack "bims"

Pack contains 432 files holding a total of 950K bytes.