Package: intron-retention-utils
intron_retention_utilsA software for calculating intron retention events genome-wide from RNA sequencing data.DependencyPythonpysam>=0.9.0,annot_utils>=0.3.0packages.Softwarebedtools,hstlibInstallpip install intron_retention_utilsAlternatively, you can install from the source code.git clone  https://github.com/friend1ws/intron_retention_util.git
cd intron_retention_utils
python setup.py build installThis package has been tested on Python 2.7, 3.5, 3.6.PreparationForallele_countcommand, aSmith-Waterman shared libraryfrom Mengyao Zhao is necessary.
Also, if your BAM file is aligned to reference genome using name convention other than UCSC,
Create thelibssw.soand add the path to the LD_LIBRARY_PATH environment variable.Commandssimple_countSimple intron retention count program.
Calculate the number of reads covering each exon-intron boundary and
putative intron retention reads (that covering enlarged reagion by specified margin size (e.g. -5bp and +5bp from that boundary).intron_retention_utils simple_count [-h] 
                                    [--grc]
                                    [--genome_id {hg19,hg38,mm10}]
                                    [--intron_retention_check_size intron_retention_check_size]
                                    [--mapping_qual_thres mapping_qual_thres]
                                    [--keep_improper_pair] [--debug]
                                    sequence.bam output_fileAbout resultChr: chromosome of the exon-intron boundaryBoundary_Pos: coordinate of the exon-intron boundary (the last exonic base)Gene_Symbol: gene symbol from refGene.txt.gzMotif_Type: splicing donor or acceptorStrand: transcription starnd of the geneJunction_List: cannonical splicing junction list from that exon-intron boundaryGene_ID_List: refGene ID list with that exon-intron boundaryExon_Num_List: exon numbers for each refGene IDsEdge_Read_Count: the number of reads covering each exon-intron boundaryIntron_Retention_Read_Count: the number of putative intron retention readsallele_countintron_retention_utils allele_count [-h] 
                                    [--grc]
                                    [--genome_id {hg19,hg38,mm10}]
                                    [--donor_size donor_size]
                                    [--acceptor_size acceptor_size]
                                    [--template_size check_size]
                                    [--template_score_margin check_size]
                                    [--read_search_margin read_search_margin]
                                    [--debug]
                                    sequence.bam mutation.txt
                                    output.txt reference.faAbout resultGene_Symbol: gene symbolChr_Mut: chromosome of the mutationStart_Mut: start coordinate of the mutationEnd_Mut: end coordinate of the the mutationRef_Mut: reference allele of the mutationAlt_Mut: alternative allele of the mutationChr_Motif: chromosome of the splicing motifStart_Motif: start coordinate of the splicing motifEnd_Motif: end coordinate of the splicing motifType_Motif: donor or acceptorStrand_Motif: transcription strand of the geneSplice_Junction_Negative: the number of normaly spliced reads without the alternative alleleSplice_Junction_Positive: the number of normaly spliced reads with the alternative alleleIntron_Retention_Negative: the number of putative intron retention reads without the alternative alleleIntron_Retention_Positive: the number of putative intron retention reads with the alternative allelemerge_controlMerge the intron retention file of control data (typically) for later filtering.intron_retention_utils merge_control [-h] 
                                     [--ratio_thres RATIO_THRES]
                                     [--sample_num_thres SAMPLE_NUM_THRES]
                                     intron_retention_list.txt
                                     output_filefilterFilter out intron retentions that do not satisty specified conditionsintron_retention_utils filter [-h] 
                              [--num_thres NUM_THRES]
                              [--ratio_thres RATIO_THRES]
                              [--pooled_control_file POOLED_CONTROL_FILE]
                              intron_retention.txt output.txtassociateAssociate intron retention counts (typically output of simple_count commands) with mutationsintron_retention_utils associate [-h] [--donor_size donor_size]
                                        [--acceptor_size acceptor_size]
                                        [--mutation_format {vcf,anno}]
                                        [--reference reference.fa] [--sv]
                                        [--intron_margin intron_margin]
                                        [--debug]
                                        intron_retention.txt mutation.txt
                                        output_fileAbout resultThe following columns are added to the input files:Mutation_Key: vcf format mutation aggregated by commasMotif_Pos: coordinate of motif positionsMutation_Type:splicing donor disruptionorsplicing acceptor disruptionIs_Canonical: whether the mutation is disrupting cannonical splicing motifs (GT-AG) or notIntron_Retention_Type:direct-impactoropposite-side-impact