Table of Contents


Contig DNA manipulation object

Introduction

This method creates a pseudo-FIG object for use by the FullLocation object. It supports the contig_ln and dna_seq methods.

Note that it keeps all the data structures in memory, so it should not be used except for a few genomes with small number of gen

Public Methods

new

my $cdna = ContigDNA->new($genID1 => $file1, $genID2 => $file, ... $genIDN => $fileN );

Construct a new pseudo-FIG object from a set of FASTA files. The incoming parameters come in pairs. The first of each pair is the ID of a genome; the second is the name of a FASTA file containing the contig data.

genID1, genID2, ... genIDN

IDs of the genomes whose contigs are to be read into memory.

file1, file2, ... fileN

Names of the FASTA files containing the genome data.

dna_seq

my $sequence = $sfxlate->dna_seq($genomeID, @locations);

Return the sequence represented by a list of locations. The locations should be in the standard form contigID_begindirend.

genomeID

ID of the relevant genome.

location1, location2, ... locationN

List of locations to be included in the DNA sequence.

RETURN

Returns a string specifying the DNA nucleotides in the specified locations.

contig_ln

my $length = $sfxlate->contig_ln($genomeID, $contig);

Return the length of the specified contig.

genomeID

ID of the genome to which the contig belongs.

contigID

ID of the contig whose length is desired.

RETURN

Returns the length (in base pairs) of the specified contig in the specified genome.