Skip to content

Small script to produce iTOL colorstrip metadata files from a table

License

Notifications You must be signed in to change notification settings

boasvdp/itolparser

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

itolparser

Small script to produce iTOL colorstrip metadata files from a table

Background

iTOL is a web interface to display and manipulate phylogenetic trees, together with metadata. Producing these metadata files can be cumbersome, which is why this script might come in handy.

Method

itolparser takes a table as input file, and loops through each column. By default, all columns are parsed as categorical. Specific columns can be parsed as continuous by providing a comma-separated list of column names with --continuous or ignore columns with --ignore.

For categorical columns, colours are selected based on the number of categories in the column. If there are more than 18 values, random colours are generated. Additionally, an annotation file will be created (labeled with _filtered) where a maximum number of colours is used, sorted on occurrence (controlled by --maxcategories) and uses grey color for other categories. This is e.g. useful for ST typing, which is categorical data often with a lot of different values.

Output files are written to a directory. Parameters such as margin and colorstrip width can be controlled with --margin and --stripwidth respectively (these can also be changed online in iTOL itself).

Bugs and suggestions

Create an issue or shoot me an email at boas [dot] vanderputten [at] amsterdamumc [dot] nl

About

Small script to produce iTOL colorstrip metadata files from a table

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages