Running GView - phac-nml/gview-wiki GitHub Wiki
For help installing and running GView, see the quick start tutorial available here.
GView can be executed directly by double-clicking on the gview.jar file, found within the download section. This will bring up an Open dialog similar to the one shown, which can be used to select the files and a layout to render a genomic map from. This window can also be displayed if the command java -jar gview.jar is executed from the command line.
To run GView from the command line execute "java -jar gview.jar " where the arguments are as follows:
Short Flag | Long Flag | Argument Type | Description | Required |
---|---|---|---|---|
-h | --help | Print the usage. | ||
-H | --height | integer | Specifies the height in pixels for the image. | |
-c | --centerBase | integer | Specifies the base to center on. | |
-i | --inputFile | file name or URL | The input file to parse. | ✔ |
-l | --layout | layout | The layout of the input, circular or linear. | |
-o | --outputFile | file name | The image file to create. | ✔ (if not using -v) |
-f | --imageFormat | format | The format of the output: [png, jpg, svg, svgz] (default:png) | ✔ (with -o) |
-v | --viewer | Loads up the input file in the viewer. | ✔ (if not using -o) | |
-s | --style | file name or URL | The file from which to read the style information from. | |
-g | --gffFile | file name | Specifies a .gff file with additional annotations to include. This can be specified multiple times to include multiple files. | |
-b | --birdsEyeView | Displays a birds eye view of the map. This is ignored if -v is not used. | ||
-W | --width | integer | Specifies the width in pixels for the image. | |
-z | --zoomAmount | real number | The factor to zoom in by. | |
-q | --quality | quality | The quality to render GView with. Either high or low. | |
-t | --threads | integer | The number of threads to run GView with. By default this is the maximum GView can acquire from the JVM. | |
--version | Prints version information for GView. |
Examples:
java -jar gview.jar -i example_data/NC_007622.gbk -s example_styles/basicStyle.gss -l linear -W 1200 -H 900 -f png -o image.png
java -jar gview.jar -i example_data/NC_007622.gbk -s example_styles/gssExample.gss -l circular -v -b
Note: If you obtain an "Out of Memory" error when drawing a very large map, try increasing Java's heap size using the -Xmx option. For example:
java -Xmx512M -jar gview.jar -i example_data/NC_007622.gbk -s example_styles/gssExample.gss -l circular -v -b
Specify the genome data to read with this option. GView can read Genbank DNA files and display gene regions explicitly specified in the file. For backwards compatibility with CGView, GView will read CGView tab delimited or CGView XML files. GView uses feature information from Genbank files to identify the location and names of genes in the genome. The Genbank DNA file must end with the ".gbk" file extension.
This option will cause GView to open an interactive viewing window. The view can be manipulated using the mouse and keyboard.
GView can render static images and write the results to a file without opening the interactive viewer. Static images can be exported from the interactive mode using a keyboard shortcut.
This option is used to control the output image format of the file written with the -o option. GView currently supports png, jpg, svg, and svgz image formats. If this option is not specified, the default format will be png.
GView can render genomes in either a circular or linear layout.The default option is linear, so to specify the circular layout use "-l circular". The shorter forms c or l are also accepted.
Use this option to supply style information to GView. The file must contain GSS (GView StyleSheet) information. If no style information is provided, a default style with only two slots (one for genes coding in the forward direction, and one for genes in the reverse direction) will be used.
Information not available in the sequence Genbank file can be included by specifying a GFF file with additional annotations to read. The additional features can be styled separately in a GSS file.
GView can be rendered in either high or low quality. The shorter forms h and l are also acceptable. The default is high quality. High quality displays all information normally and low quality displays only minimal graphical information. Some features may render differently in low quality and require high quality view to observe them properly.
These options are available when using GView in interactive mode, which is specified by the -v option. -b Displays a bird's eye view window This option will only have an effect when GView is in the Interactive Viewer mode (-v). With this option set, an additional window with a miniaturized view of the genome will be shown. The area being shown in GView is highlighted in the bird's eye view, providing additional context.
These options are available when using GView in Non-interactive mode, which is specified by the -o option.
This option is used when running GView in non-interactive mode. This option will centre the view on a specific region of the genome. When used in conjunction with the zoom factor option, images of a smaller region of the genome will be produced.
This option is used when running GView in non-interactive mode. This option will set the zoom factor for the image, determining how many base pairs along the backbone that will be visible. Appropriate values for the zoom factor range from 1.0 -- 1000.0. The default zoom factor is 1.0.
Sets the height of the image produced by GView in non-interactive mode.
Sets the width of the image produced by GView in non-interactive mode.