This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Tutorial: Introduce OpenGene: an open source library for processing NGS data

OpenGene, core libraries for NGS data analysis and bioinformatics, written in julia

OpenGene already supports fastq/fasta/vcf/gtf/bed reading and writing, and also gives sam/bam reading/writing support with HTSLIB

Call for contributors!

We need more heros to make OpenGene a fast, easy-to-use and powerful genetics toolkit.

Examples

read/write a single fastq/fasta file

using OpenGene

istream = fastq_open("input.fastq.gz")
ostream = fastq_open("output.fastq.gz","w")

while (fq = fastq_read(istream))!=false
    fastq_write(ostream, fq)
end

close(ostream)

fasta is supported similarly with fasta_open, fasta_read and fasta_write

read/write a pair of fastq files

using OpenGene

istream = fastq_open_pair("R1.fastq.gz", "R2.fastq.gz")
ostream = fastq_open_pair("Out.R1.fastq.gz","Out.R2.fastq.gz","w")

while (pair = fastq_read_pair(istream))!=false
    fastq_write_pair(ostream, pair)
end

close(ostream)

read/write a bed file

using OpenGene

intervals = bed_read_intervals("in.bed")
bed_write_intervals("out.bed",intervals)

read/write a VCF

using OpenGene

vcfobj = vcf_read("in.vcf")
vcf_write("out.vcf", vcfobj)

read/write a GTF

using OpenGene

gtfobj = gtf_read("in.gtf")
gtf_write("out.gtf", gtfobj)

gtfobj, stream = gtf_read("in.gtf", loaddata = false)
while (row = gtf_read_row(stream)) != false
    # do something with row ...
end

locate the gene/exon/intron

using OpenGene, OpenGene.Reference

index = gencode_load("GRCh37")

gencode_locate(index, "chr5", 149526621)
# 1-element Array{Any,1}:
#  Dict{ASCIIString,Any}("gene"=>"PDGFRB","number"=>1,"transcript"=>"ENST00000261799.4","type"=>"intron")
ngs sequencing julia opengene

The above tutorial was helpful to give a good seminar in my class.

Hi sudharshanva, please use ADD REPLY for comments. The answer field is intended for answers only.

0 answers

No answers yet.

Log in to answer this question.