Skip to content

Ykabrit/PAGviz

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

PAGviz

PAGviz is a simple command-line interface for displaying Partial Ancestral Graphs (PAGs), Directed Acyclic Graphs (DAGs) or Complete Partial DAGs (CPDAGs) exported in a text format from the Tetrad program for causal discovery.

It can output the graph either as an image (.png by default) generated by the pydot Python package, or a .dot file that can be edited and displayed separately using any Graphviz-compatible software. The image can also be sent to stdout as an option (tested on a Linux machine).

Usage

PAGviz [-h] [-w] [-f FILE_OUTPUT] [-t] input_file

Simple command to convert a PAG (Partial Ancestral Graph) in a TXT format exported from Tetrad into a DOT format with a color scheme for the different edge types, and output as an image
or DOT file.

positional arguments:
  input_file

options:
  -h, --help            show this help message and exit
  -w, --white-background
                        Add a white background to the graph instead of OldLace

output:
  Choose one or more output modes

  -f, --file-output FILE_OUTPUT
                        A path with a filename (with the extension) to save the output to a desired location. If the extension is `.dot`, a DOT file is produced instead of an image.
                        Example: './output_pag.png' or '../dot_files/output_pag.dot'
  -t, --terminal-output
                        Output the result to stdout in the PNG format.

About

Simple CLI tool to convert Partial Ancestral Graphs (PAG) or Directed Acyclic Graphs (DAG) from a TXT format exported from the Tetrad program into a DOT format interpretable by Graphviz for visualization, or directly into an image.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages