================
 Description
================
TransBorrow is an efficient genome-guided trascriptome assembler for RNA-seq data. It can 
assemble all transcripts with the help of other assemblers to obtain more accurate assemblies.
The software expects as input an alignment file in BAM format, the combined assemblies from 
the other assemblers in GTF format, and outputs all assembled candidate transcripts in gtf format. 

This software is free to use, modify, redistribute without any restrictions,	
except including the license provided with the distribution.

================
 Installation
================
 
 Note: Please make sure that Cmake is installed in your Linux system.

 1. Installing Boost

    a) download a version of boost and unpack it

       $ tar zxvf boost_1_47_0.tar.gz

    b) change to the boost directory and run ./bootstrap.sh

       $ cd boost_1_47_0
       $ ./bootstrap.sh

    c) run

       $ ./b2 install --prefix=<YOUR_BOOST_INSTALL_DIRECTORY>

       For example, if you want install boost in /home/juntaosdu/local/boost, the command is :
      
       $ ./b2 install --prefix=/home/juntaosdu/local/boost

       If the boost is installed successfully, you would find two sub-directories 
       in /home/juntaosdu/local/boost/:

       /home/juntaosdu/local/boost/include/
       /home/juntaosdu/local/boost/lib/

      Note: The default Boost installation directory is /usr/local. Take note of the boost 
      installation directory, because you need to tell the TransBorrow installer where to find 
      boost later on.

      (WARNING: The paths of "boost/lib/" and "boost/include/" should be added to the 
      CMakeList.txt of TransBorrow in TransBorrow_v.1.2/src/ later on.)

 2. Installing BamTools
   
    a) change to the bamtools directory and make a new directory named "build"

       $ cd TransBorrow_v.1.2/bamtools
       $ mkdir build
       $ cd build

    b) type cmake and make it install

       $ cmake ../
       $ make

      Note: Go back up to the BamTools root directory. 
      
      1) Assuming the build process finished correctly, you should be able to find 
      the toolkit executable here:
      
      ./bin/
      
      2) The BamTools API and Utils libraries will be found here:
      
      ./lib/
      
      3) The BamTools API headers will be found here:
      
      ./include/*

      (WARNING: The paths of ./lib/ and ./include/ should be added to the CMakeList.txt 
      of TransBorrow in TransBorrow_v.1.2/src/ later on.)

 3. Building TransBorrow

      a) unpack the TransBorrow and change to the TransBorrow directory

       $ tar zxvf TransBorrow_v.1.2.tar.gz
       $ cd TransBorrow_v.1.2


      b) Add the lib and include paths of boost and bamtools to the CMakeList.txt 
      of TransBorrow in TransBorrow_v.1.2/src/CMakeList.txt
	
      (Note: The file CMakeList.txt will guide you how to add these two paths. Please read 
      lines 7, 9, 11, 13, 15 in CMakeList.txt for the approach of adding these two paths.)

      c) change to the TransBorrow root directory and make a new directory named "build"

       $ cd TransBorrow_v.1.2
       $ mkdir build
       $ cd build

      d) type the cmake and make commands for final building TransBorrow

       $ cmake ../src
       $ make
       $ cd ../src
       $ make
===========================================================================
Usage:

  TransBorrow [options] -r <combined_assemblies> -g <reference_genome> -b <bam_file> -s <strand_info>

** Required **

  --ref_gtf/-r <string>        : Combined transcriptome assembled by different tools in GTF format (just combine the different assemblies into a GTF file, combine.gtf);

  --ref_genome/-g <string>     : Reference genome in FASTA format;

  --bam/-b <string>            : BAM file;

  --strand/-s <string>         : Strand-specific RNA-Seq reads orientation.

                                     If reads are paired:

                                       1) Use <unstranded> to indicate RNA-seq reads are non-strand-specific;

                                       2) Use <first> to indicate fr-first-stranded RNA-seq reads;

                                       3) Use <second> to indicate fr-second-stranded RNA-seq reads;

                                     If reads are single:

                                       1) Use <single_unstranded> to indicate RNA-seq reads are non-strand-specific;

                                       2) Use <single_forward> to indicate RNA-seq reads forward;

                                       3) Use <single_reverse> to indicate NA-seq reads reverse;

** Optional **

  --min_cov/-c <float>         : Min coverage of recovered transcripts, default: 1;

  --output/-o <string>         : Output path, default: ./TransBorrow_results/TransBorrow.gtf;

  --min_trans_len/-l <int>     : Min length of recovered transcripts, default: 200;

  --cre_num/-n <int>           : Credible sub_paths assembled by at least this number of tools, default: 2;

  --min_seed/-d <float>        : Min seed coverage for extension, default: 0;

  --temp_dir/-T <string>       : Directory storing temporary files, default: ./TransBorrow_tmp;

  --threads/-t <int>           : Number of threads to launch, default: 1;

  --version/-v                 : Show current version of TransBorrow;

  --help/-h                    : help infomation;

** Typical commands **

A typical TransBorrow command for paired-end data might be:

  TransBorrow -r combine.gtf -g genome.fa -b file.bam -s first
================================================================

================
 Changelog
================

 Version 1.2
 - latest version


===============
 Authors
===============

 Juntao Liu designed and wrote TransBorrow.


================
 Contact
================
 Any questions, problems, bugs are welcome and should be dumped to
 Juntao Liu <juntaosdu@126.com>
 Created on Jul 19, 2019.

