biodb-to-json.pl
Configuration File
biodb-to-json.pl
and prepare-refseqs.pl
can use a configuration
file to connect to an existing Bio::DB::*
database and batch-format its data for use by JBrowse You
don't necessarily need a config file if all of your data is in
flat files. In this case, it is recommended that you format
your data using flatfile-to-json.pl
.
See docs/examples/format_tomato.sh
for an example of a simple shell script that
uses prepare-refseqs.pl
and flatfile-to-json.pl
to to create a complete
genome browser for Tomato.
The basic syntax of the configuration file is JSON. Many of the configuration keys are quite similar to those used by GBrowse.
The root level of the config file:
key | value | type |
---|---|---|
description | Brief description of the data source | string |
db_adaptor | Perl class that implements Bio::DasI. Common ones include
| string |
db_args | arguments to the constructor for the specified db_adaptor | dictionary of key-value pairs |
TRACK DEFAULTS | default track settings | track settings dictionary |
tracks | settings for all the tracks | array of track settings dictionaries |
The main part of the configuration file consists of the per-track settings:
key | value | type |
---|---|---|
track | track identifier used by the software. It's more convenient if this doesn't have any weird characters or spaces in it | string |
key | Human-readable label for the track | string |
feature | List of feature types to put into the track | array of strings |
autocomplete | If you want to be able to search for the features in this track, set this to one of the following strings:
| string |
class | The CSS class for the feature. Look in the feature glyph list for the available options. | string |
category | The category this track is in, for grouping the tracks together | string |
urlTemplate | Template for a URL to visit if the user clicks on a feature in this track | string |
extraData | Extra per-feature information to send to the client; useful in the urlTemplate | dictionary of header -> perl sub |
subfeatureClasses | Specifies what CSS class to apply to what type of subfeature | dictionary of type -> CSS class |
arrowheadClass | CSS class for arrowheads | string |
clientConfig | settings to control the behavior of the client for this track, mainly zoom thresholds for when to display more information | dictionary |