Documentation ¶
Overview ¶
Sets of utilities to parse Fastq/a files
Index ¶
- func ExtractFna(file, prefix, taxid string, heads map[string]bool) error
- func GetAvgQuality(input *os.File, output *os.File, phred bool) error
- func GetFileType(inf *os.File) string
- func Opener(inf, outf string) (*os.File, *os.File, error)
- func ParseFastq(r *bufio.Scanner, phred64 bool) (float64, float64)
- type Fasta
- type Fastq
- type Fna
- type Fsq
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAvgQuality ¶
GetAvgQuality takes an fastq file and attempts to calculate the average sequence quality and the sequence count. Utilises phred33 representation. usage : GetAvgQuality(<input>, <output>) Keyword arguments: input : File pointer (*os.File()), input data, either gunzipped or plain text. output : File pointer, output data containing the average quality and sequence count.
If output is nil, writes to Stdout
Return: None : Directly writes to file or Stdout
func GetFileType ¶
Types ¶
type Fna ¶
type Fna []*Fasta
func (*Fna) FilterLength ¶
Simple Utility to filter the lengths of fasta sequences. Iterates over a slice of Sequences (Fna) and filters out the sequences whose lengths are lower or greater than the specified mininimum and maximum. If maximum <= 0, max is set to the length of the sequence. Returns filtered Fna