LRez  v2.1
Functions
barcodesExtraction.h File Reference
#include "utils.h"
#include "robin_hood.h"
Include dependency graph for barcodesExtraction.h:

Go to the source code of this file.

Functions

robin_hood::unordered_set< barcodeextractBarcodesBitsFromRegion_BamReader (BamReader &reader, string region)
 
robin_hood::unordered_set< string > extractBarcodesSeqsFromRegion_BamReader (BamReader &reader, string region)
 
robin_hood::unordered_set< barcodeextractBarcodesBitsFromRegion (string bamFile, string region)
 
robin_hood::unordered_set< string > extractBarcodesSeqsFromRegion (string bamFile, string region)
 
robin_hood::unordered_set< barcodeextractBarcodesBitsFromBAM (string bamFile, unsigned nbThreads=1)
 
robin_hood::unordered_set< string > extractBarcodesSeqsFromBAM (string bamFile, unsigned nbThreads=1)
 
vector< barcodeextractBarcodesBitsFromRegionWithDuplicates_BamReader (BamReader &reader, string region)
 
vector< string > extractBarcodesSeqsFromRegionWithDuplicates_BamReader (BamReader &reader, string region)
 
vector< barcodeextractBarcodesBitsFromRegionWithDuplicates (string bamFile, string region)
 
vector< string > extractBarcodesSeqsFromRegionWithDuplicates (string bamFile, string region)
 
vector< barcodeextractBarcodesBitsFromBAMWithDuplicates (string bamFile, unsigned nbThreads=1)
 
vector< string > extractBarcodesSeqsFromBAMWithDuplicates (string bamFile, unsigned nbThreads=1)
 

Function Documentation

◆ extractBarcodesBitsFromBAM()

robin_hood::unordered_set<barcode> extractBarcodesBitsFromBAM ( string  bamFile,
unsigned  nbThreads = 1 
)

Extract all the barcodes of a given BAM file, in binary representation.

Parameters
bamFilebamFile BAM file to extract barcodes from
nbThreadsnumber of threads to use, set to 1 by default
Exceptions
ios_base::failurethrown if bamFile or its associated index could not be open
Returns
a set containing the barcodes present in the BAM file, in binary representation

◆ extractBarcodesBitsFromBAMWithDuplicates()

vector<barcode> extractBarcodesBitsFromBAMWithDuplicates ( string  bamFile,
unsigned  nbThreads = 1 
)

Extract all the barcodes of a given BAM file, in binary representation, including duplicates.

Parameters
bamFilebamFile BAM file to extract barcodes from
nbThreadsnumber of threads to use, set to 1 by default
Exceptions
ios_base::failurethrown if bamFile or its associated index could not be open
Returns
a vector containing the barcodes present in the BAM file, in binary representation

◆ extractBarcodesBitsFromRegion()

robin_hood::unordered_set<barcode> extractBarcodesBitsFromRegion ( string  bamFile,
string  region 
)

Extract the barcodes of a given region, in binary representation.

Parameters
readerbamFile BAM file to extract barcodes from
regionregion of interest
Exceptions
runtime_errorthrown if region could not be converted to a BamRegion or jumped to
Returns
a set containing the barcodes present in the region, in binary representation

◆ extractBarcodesBitsFromRegion_BamReader()

robin_hood::unordered_set<barcode> extractBarcodesBitsFromRegion_BamReader ( BamReader &  reader,
string  region 
)

Extract the barcodes of a given region, in binary representation.

Parameters
readerBamReader open on the desired BAM file
regionregion of interest
Exceptions
runtime_errorthrown if region could not be converted to a BamRegion or jumped to
Returns
a set containing the barcodes present in the region

◆ extractBarcodesBitsFromRegionWithDuplicates()

vector<barcode> extractBarcodesBitsFromRegionWithDuplicates ( string  bamFile,
string  region 
)

Extract the barcodes of a given region, in binary representation, including duplicates.

Parameters
readerbamFile BAM file to extract barcodes from
regionregion of interest
Exceptions
ios_base::failurethrown if bamFile or its associated index could not be open
Returns
a vector containing the barcodes present in the region, in binary representation

◆ extractBarcodesBitsFromRegionWithDuplicates_BamReader()

vector<barcode> extractBarcodesBitsFromRegionWithDuplicates_BamReader ( BamReader &  reader,
string  region 
)

Extract the barcodes of a given region, in binary representation, including duplicates.

Parameters
readerBamReader open on the desired BAM file
regionregion of interest
Exceptions
runtime_errorthrown if region could not be converted to a BamRegion or jumped to
Returns
a vector containing the barcodes present in the region

◆ extractBarcodesSeqsFromBAM()

robin_hood::unordered_set<string> extractBarcodesSeqsFromBAM ( string  bamFile,
unsigned  nbThreads = 1 
)

Extract all the barcodes of a given BAM file, in string representation.

Parameters
bamFilebamFile BAM file to extract barcodes from
nbThreadsnumber of threads to use, set to 1 by default
Exceptions
ios_base::failurethrown if bamFile or its associated index could not be open
Returns
a set containing the barcodes present in the BAM file, in string representation

◆ extractBarcodesSeqsFromBAMWithDuplicates()

vector<string> extractBarcodesSeqsFromBAMWithDuplicates ( string  bamFile,
unsigned  nbThreads = 1 
)

Extract all the barcodes of a given BAM file, in string representation, including duplicates.

Parameters
bamFilebamFile BAM file to extract barcodes from
nbThreadsnumber of threads to use, set to 1 by default
Exceptions
ios_base::failurethrown if bamFile or its associated index could not be open
Returns
a vector containing the barcodes present in the BAM file, in string representation

◆ extractBarcodesSeqsFromRegion()

robin_hood::unordered_set<string> extractBarcodesSeqsFromRegion ( string  bamFile,
string  region 
)

Extract the barcodes of a given region, in string representation.

Parameters
readerbamFile BAM file to extract barcodes from
regionregion of interest
Exceptions
runtime_errorthrown if region could not be converted to a BamRegion or jumped to
Returns
a set containing the barcodes present in the region, in binary string

◆ extractBarcodesSeqsFromRegion_BamReader()

robin_hood::unordered_set<string> extractBarcodesSeqsFromRegion_BamReader ( BamReader &  reader,
string  region 
)

Extract the barcodes of a given region, in string representation.

Parameters
readerBamReader open on the desired BAM file
regionregion of interest
Exceptions
runtime_errorthrown if region could not be converted to a BamRegion or jumped to
Returns
a set containing the barcodes present in the region

◆ extractBarcodesSeqsFromRegionWithDuplicates()

vector<string> extractBarcodesSeqsFromRegionWithDuplicates ( string  bamFile,
string  region 
)

Extract the barcodes of a given region, in string representation, including duplicates.

Parameters
readerbamFile BAM file to extract barcodes from
regionregion of interest
Exceptions
ios_base::failurethrown if bamFile or its associated index could not be open
Returns
a vector containing the barcodes present in the region, in binary string

◆ extractBarcodesSeqsFromRegionWithDuplicates_BamReader()

vector<string> extractBarcodesSeqsFromRegionWithDuplicates_BamReader ( BamReader &  reader,
string  region 
)

Extract the barcodes of a given region, in string representation, including duplicates.

Parameters
readerBamReader open on the desired BAM file
regionregion of interest
Exceptions
runtime_errorthrown if region could not be converted to a BamRegion or jumped to
Returns
a vector containing the barcodes present in the region