This function draws Evolution Highway style plots.
It requires as input:
Desired output file name
The range of chromosomes of the reference species this is entered as either a single number i.e. 1 or a range of numbers i.e. 1:22.
Note: if you are inputting sex chromosomes or chromosomes with characters in the name input a concatenated string i.e. c(1,2,3,"X")
File containing the syntenic blocks of alignments of one or more target species aligned to a single reference; following this format:
reference chromosome, reference start position, reference end position, target chromosome,
target start position, target end position, orient, reference species identifier, target species identifier
There are optional parameters for some customization of this function:
The format for saving the image i.e. png or pdf can be altered by inputting: fileformat = "pdf" (the default value is "png")
The colour of the syntenic blocks (not inverted blocks) can be changed by inputting: colour = "red" (the default value is "lightblue", see Rcolour pallette for colour options)
The colour of the inverted syntenic blocks can be changed by inputting: inverted.colour = "blue" (the default value is "lightpink", see Rcolour pallette for colour options)
The width of the image created can be changed by inputting: w = 5.5
The height of the image created can be changed by inputting: h = 10
The point size of the image created can be changed by inputting: ps = 10
The directory where the image file should be saved, as default the image is saved to temporary directory, change by inputting: directory = "path/to/directory"
The function works creating a graph for each reference chromosome using their start and end positions to create a block for the reference
and the target chromosome positions are used to colour the region where synteny was identified
Example: draw.eh("outputName",c(17,"X"), "example_eh_alignments_2.txt", directory = "path/to/directory", fileformat = "pdf")