Next: MMapView, Up: Visualization

### 4.1 MapView

MapView is designed to draw markers and QTL for one or several linkage groups, depending on drawing parameters.

#### 4.1.1 Command Line Options

Option | Usage | Type | Explanation
--- | --- | --- | ---
`-m,--mapfile` | required | string | The XML file for the genetic map.
`-c,--chrom` | required | string | The name of the chromosome(s) to display.
`-o,--output` | required | string | The output file stem.
`-q,--withqtl` | optional | integer | Draw also QTL.
`-t,--tonto` | optional | string | The XML file for the trait ontology
`-p,--parfile` | optional | string | The drawing parameter file.
`--qmode` | optional | integer | QTL representation mode (0=bar,1=arrow)
`--tree` | optional | string | a QTL tree (obtained with QTLTree);
`--img` | optional | string | The format of the image (use –help for possible values).

For example,

         %java org.metaqtl.main.MapView \
         >     -c 1,2 -m map.xml -q -o figure --img jpeg

draws the chromosome 1 and 2 with both markers and QTL of the given map `map.xml` and outputs the result in `figure.jpeg`. This also creates a file named `figure.par` which gives the values of the drawing paremeters. This file can be modified and reused to create another image by using the `-p` or `--par` option

         %java org.metatqtl.main.MapView \
         >     -c 1,2 -m map.xml -q -o figure -p figure.par --img jpeg

The next section gives more details on how to deal with the drawing parameters.

#### 4.1.2 Drawing Parameters

Several parameters allow user to put in form the figure. The next figure illustrates the role of each parameter.

Figure 4.1: Details of formatting parameters for MapView.

The paremeter file is organized as follows:

         #
         # Graphical Parameters
         #
         # CHROMOSOME
         #
         CHROM_DISTANCE_SCALE=5.0
         CHROM_FLANKING_CEX=0.1
         CHROM_NAME_FONT=Utopia Regular:BOLD:12
         CHROM_NAME_HSPACE=20.0
         CHROM_TICK_WIDTH_1=10.0
         CHROM_TICK_WIDTH_2=20.0
         CHROM_TICK_WIDTH_3=10.0
         CHROM_WIDTH=30.0
         MAKER_NAME_VSPACE=1.0
         MARKER_NAME_FONT=Utopia Regular:PLAIN:10
         MARKER_POSITION_FONT=Utopia Regular:PLAIN:10
         #
         # QTL
         #
         QTL_CI_WIDTH=10.0
         QTL_CI_WIDTH_CEX=0.25
         QTL_HSPACE=10.0
         QTL_NAME_FONT=Courier:PLAIN:10
         QTL_NAME_VSPACE_CEX=1.0
         QTL_POS_HEIGHT_CEX=0.01
         QTL_POS_WIDTH_CEX=1.5
         QTL_VSPACE=20.0
         #
         # LEGEND
         #
         LEGEND_BOX_CEX=0.5
         LEGEND_FONT=Verdana:PLAIN:10
         LEGEND_HSPACE=5.0
         LEGEND_PART_HEIGHT=20.0
         LEGEND_PART_WIDTH=50.0
         LEGEND_SCALE_UNIT=5
         #
         # OTHER
         #
         BACKGROUND_COLOR=ffffff
         LAYER_HSPACE=20.0
         LAYER_VSPACE=20.0
         WITH_CHROM_NAME=true
         WITH_LEGEND=true
         WITH_MAP_NAME=true
         WITH_MARKER_NAME=true
         WITH_QTL_NAME=true
         WITH_MARKER_POSITION=true

A line which begins by the character ```#``' is ignored by the program. Each drawing parameter is specified by its own name directly followed by a sign ```=``' and its value. For the parameters which specify a color (those which end by ```_COLOR``') the value must be a RGB code in hexadecimal (e.g red is ff0000, green 00ff00, blue 0000ff, white ffffff, black 000000, and etc...). For the parameters which specify a font (those which end by ```_FONT``') the value must be a string composed by 3 tokens separated by a ```:``'. The first token gives the name of the font, the second one the style of the font (among ```PLAIN,BOLD``' and ```ITALIC``') and the last one indicates the size of the font. The parameter file generated by MapView ends by a list of the available fonts on your system. If you do not use a font name in this list, then MapView will use the default font. The parameters which start by ```WITH_``' allow the user to specify if the corresponding elements of the figure must be drawn. The possible values for these parameters are either ```true``' (draw) and ```false``' (not to draw). For example if you set ```WITH_MARKER_POSITION=false``' the marker positions along the chromosome wont' be drawn. When the QTL are added to the figure (option `-q` with MapView) they are colored according to their trait group. The colors used to display the QTL are also specified in the parameter file generated by the program. For example, let's assume that the QTL belongs to 3 trait groups. The parameter file will then contain the following lines:

         #
         # COLOR PALETTE
         #
         QTL_COLOR_1=ffff00
         QTL_COLOR_2=00ff00
         QTL_COLOR_3=0000ff

where `QTL_COLOR_i` is the color of the group `i`. You can use these lines to modify the default colors.