Giter VIP home page Giter VIP logo

hpviewer's Introduction

HPViewer: sensitive and specific genotyping of human papillomavirus in metagenomic DNA

Description

HPViewer is a tool for genotyping and quantification of HPV from metagenomic or human genomic shotgun sequencing data. We designed it to improve performance by masking nonspecific sequences from reference genomes and directly identifying HPV short DNA reads. It contains two HPV databases with different masking strategies, repeat-mask and homology-mask and one homology distance matrix to choose between those two databases.

If you use the HPViewer software, please cite our manuscript:

Yuhan Hao, Liying Yang, Antonio Galvao Neto, Milan R Amin, Dervla Kelly, Stuart M Brown, Ryan C Branski, Zhiheng Pei; HPViewer: sensitive and specific genotyping of human papillomavirus in metagenomic DNA, Bioinformatics, bty037, https://doi.org/10.1093/bioinformatics/bty037

Installation

$ git clone https://github.com/yuhanH/HPViewer.git

Pre-requisites

Python (2.7+)

Python packages (sys, getopt, subprocess)

Bowtie2: http://bowtie-bio.sourceforge.net/bowtie2/manual.shtml

SAMtools: http://www.htslib.org/

Bedtools: http://bedtools.readthedocs.io/en/latest/

Parameters

Required

a) input files (-U or -1 -2): fastq files (or fastq.gz), unpaired (-U unpaired.fastq) or R1,R2 paired (-1 R1.fastq -2 R2.fastq)

b) output file name (-o)

Optional

a) database mask type (-m): hybrid-mask(default), repeat-mask, homology-mask.

If you set -m, it should be in front of reads input (-m repeat-mask -1 R1.fastq -2 R2.fastq). Repeat-mask is a more sensitive mode; and homology-mask is suggested when some types of HPV are present in large abundance which may lead to false positive of other types of HPV.

b) number of threaded used in bowtie2 alignment (-p)

c) minimal coverage threshold to determine HPV present (-c), default is 150 bp (1.5 x average length of your reads).

Results

a) output_HPV_summary.txt has three coloumns with types of HPV present, number of reads per kilobase (RPK) for the matching HPV, and number of reads of the matching HPV.

b) alignment results after bowtie2: output.sam, output.bam

Basic Usage (demo)

python HPViewer.py -U test_unpaired.fastq -o TEST
more TEST/TEST_HPV_profile.txt

Work Flow

hpviewer's People

Contributors

yuhanh avatar

Stargazers

Anatoly Chernov avatar Forever avatar  avatar Isaac Pei avatar Peter Zeng avatar  avatar yzhou avatar  avatar Huang avatar Wendy Wong avatar MISHIMA, Hiroyuki avatar Jin Choul Chai avatar Colin Davenport avatar

hpviewer's Issues

error in lines 317, 310

this is the error I got when trying to run HPViewer on a sample metagenomic data -
Traceback (most recent call last):
File "/home/tirosho/HPViewer/HPViewer.py", line 317, in
quant_HPV(outprefix,min_cov)
File "/home/tirosho/HPViewer/HPViewer.py", line 310, in quant_HPV
coverage=str("%.4f" % (1000*float(d2[hpv])/float(d3[hpv])))
KeyError: 'HPV131'

I checked and saw HPV131 is not in the distant matrix database. does this cause the problem? or something else?

updating - I just tried it with another file and got the same error for HPV150, I guess it's not the HPV type that is the problem. Am I missing a python module?

Script/pipeline to update the database?

There are currently 182 types in the pre-built database, however PaVE now has >220, and so I was wondering if there was a script to re-generate the necessary input databases?

cov option does not work

-cov option does not work, will be interpreted as -o v
resulting in a 'v' directory wherein all your output is continuously overwritten.

fix hint: replace cov by single character option c:

print("   -c    <INT>    minimal coverage threshold to determine HPV present, default is 150 bp.")
...
getopt.getopt( sys.argv[1:], "U:1:2:m:o:p:c:h", ["help" ] )
...
if opt in ( "-c", ):
            min_cov = str(val)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.