Giter Club home page Giter Club logo

tikz-bayesnet's Introduction

BayesNet

TikZ library for drawing Bayesian networks, graphical models and (directed) factor graphs in LaTeX.

Contents

Provides the following node styles:

  • latent
  • obs
  • det
  • const
  • factor
  • plate
  • gate

Provides the following commands (note that any of the arguments can be empty):

  • \factor [options] {name} {caption} {inputs} {outputs}
  • \plate [options] {name} {fitlist} {caption}
  • \gate [options] {name} {fitlist} {inputs}
  • \vgate {name} {fitlist-left} {caption-left} {fitlist-right} {caption-right} {inputs}
  • \hgate {name} {fitlist-top} {caption-top} {fitlist-bottom} {caption-bottom} {inputs}
  • \edge [options] {inputs} {outputs}
  • \factoredge [options] {inputs} {factors} {outputs}

Usage

Install the package by copying tikzlibrarybayesnet.code.tex to your LaTeX system or copy the file into projects that are using it. To use the library in your LaTeX file

\usepackage{tikz}
\usetikzlibrary{bayesnet}

Compile the LaTeX example:

pdflatex example.tex

and see the resulting PDF file example.pdf.

Example

PCA model as a Bayesian network and a directed factor graph.

PCA model as a Bayesian network and a directed factor graph.

Directed factor graph of the citation influence model.

Directed factor graph of the citation influence model.

This library is derived from a technical report "Directed Factor Graph Notation for Generative Models" and the accompanying TikZ macros by Laura Dietz 2010 (http://people.cs.umass.edu/~dietz/). The technical report is available in this repository as dietz-techreport.pdf.

GraphViz (http://www.graphviz.org/) is a more general open source graph visualization software. It uses DOT file format to describe the structure of the graph. The DOT file can be converted to LaTeX using dot2tex (http://www.fauskes.net/code/dot2tex/).

UAI (http://graphmod.ics.uci.edu/uai08/FileFormat) is a simple text file format to describe Markov networks. The UAI file format can be converted to DOT file format using uai2dot (https://github.com/drewfrank/uai2dot).

License

Copyright (C) 2010-2011 Laura Dietz
Copyright (C) 2012 Jaakko Luttinen [email protected]

This work is released under the MIT license.

tikz-bayesnet's People

Contributors

jluttine avatar brendano avatar

Watchers

James Cloos avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.