Table of Contents |
---|
Introduction
An IGB script file (available starting Starting with IGB 6.3) is , IGB supports a simple batch file that allows a user to run sequential commands outside of IGB, either at startup (scripting language that contains commands related to loading data from files and URLs.
Scripts can be run
- At startup, via a command-line option
...
- From IGB links
- Using the File > Open command (provided the file name ends with .igb)
- By drag-and-drop, dragging the file into an open IGB window
Syntax
The script file has a simple, space-delimited syntax.
Supported commands
...
Each command should occupy a separate line.
Commands
Specify a genome version
Code Block |
---|
genome <version>
|
Specify a genome version (e.g., H_sapiens_Mar_2006). Any genome version or synonym that's accepted by IGB is accepted here.
Go to a region
Code Block |
---|
goto <region> |
Go to a region of a chromosome (e.g., "chr1:40000-60000"). Any format that's accepted by IGB is accepted here.
Add a new data set to IGB's list of active data sets.
Code Block |
---|
load <file or URL> |
Load the specified file (identified by full path) or URL into IGB. The data set will appear in the user's Data Management table upon completion.
Change the load mode for an active data set.
Code Block |
---|
loadmode <NO_LOAD | REGION_IN_VIEW | CHROMOSOME | GENOME> <file or URL> |
Change the load mode for the specified
...
data set or file, identified by full path
...
refresh
...
.
Load data from currently active data sets.
Code Block |
---|
refresh
|
This is equivalent to clicking the Load Data button in IGB. This triggers loading of data from the
...
active data sets available in IGB, as specified in the load command.
Making images
...
Code Block |
---|
snapshot |
...
<filename> |
...
|
Code Block |
---|
snapshotwholeFrame |
...
<filename> |
...
|
Code Block |
---|
snapshotmainView |
...
<filename> |
...
|
Code Block |
---|
snapshotmainViewWithLabels |
...
<filename> |
...
|
Code Block |
---|
snapshotslicedViewWithLabels |
...
<filename> |
...
|
Export the entire frame, main view, main view with labels, or sliced view, respectively, to a an image file.
...
The filename extension determines the format.
Supported formats are those supported by IGB Export function
...
.
...
The filename defaults to "<genome_version><timestamp>.png" if not specified.
Select genes.
Code Block |
---|
select <geneids> |
Selects the given gene IDs, which are passed in as a comma-separated list.
Wait (sleep) for commands to finish
Code Block |
---|
sleep <milliseconds> |
Sleep the application for x milliseconds.
...
# Comment
...
Note |
---|
IGB is mult-threaded, which means that the user may be able to operate IGB while data are being loaded. If your IGB script includes loading data from remote sites (e.g, RNASeq data from the IGBQuickLoad.org site) then you should include a sleep command to give IGB time to load the data. |
Comments
Lines starting with the IGB script comment character '#' are ignored.
Example script
Panel |
---|
Code Block |
# select genome genome A_thaliana_Jun_2009 #go to chromosome at region goto# go to a region in chr4 goto chr4:18,040,000 - 18,045,056 #load the file load# load a file load http://igbquickload.org/quickload/A_thaliana_Jun_2009/nextgen_samples/sample.bam #set load mode to region in view loadmode# set load mode to region in view loadmode REGION_IN_VIEW VIEW http://igbquickload.org/quickload/A_thaliana_Jun_2009/nextgen_samples/sample.bam #refresh to view data refresh
# load the data
refresh
|