Skip to content

peterrhysstrong/cegpy-binder

Repository files navigation

cegpy-binders

The following binders provide examples for using the cegpy package. API documentation can be found at cegpy.readthedocs.org.

Basic Example: Binder

This first example builds a Chain Event Graph (CEG) from a discrete dataset showing results from a medical experiment. The dataset used is symetrical, built from a rectangular dataset. These CEGs are known as stratified in the literature.

Non-stratified Example: Binder

This example builds a Chain Event Graph (CEG) from a asymmetric dataset. In simple words, a dataset is asymmetric when the event tree describing the dataset is not symmetric around its root. The class of CEGs built from asymmetric event trees is said to be non-stratified.

CEG Reduction Example: Binder

A complete CEG shows all possible trajectories that an individual undergoing the process might experience. However, on observing any evidence, certain or uncertain, some edges and nodes become unvisited with probability 1. The CEG model can be reduced such that these edges and nodes are excluded, without any loss of information. Once reduced, the probabilities displayed can be also be revised.

Sampling Missing Values Example: Binder

The package, by default, treats all blank and NaN cells as structural missing values. However, sometimes these might occur due to sampling limitations. On the other hand, we might not observe a certain value for a variable (given its ancestral variables) not because that value is a structural zero but because of sampling limitations.

In this example we cover two things,

  1. How to define arguments to allow the package to distinguish between structual and sampling missing values?
  2. How to add a value which has not been observed in the dataset due to sampling limitations (i.e. its frequency is a sampling zero)?

AHC Customisation Example: Binder

The AHC is typically loaded with certain default parameters. If these are not suitable for your application, these can be modified.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •