Learn R Programming

TrustVDJ (version 0.1.0)

ReadTrust: Read AIRR/TRUST4 report files

Description

ReadTrust reads AIRR file and/or barcode_report/report file generated by TRUST4. Generally AIRR file: airr.tsv, barcode_airr.tsv (from TRUST4); barcode_report file: barcode_report.tsv; report file: report.tsv. (.gz supported)

  1. AIRR + barcode_report: ReadTrust will read AIRR and add it a 'cdr3_germline_similarity' column based on barcode_report.

  2. only one file: ReadTrust will return a data.frame for this file.

  3. AIRR/barcode_report + report: ReadTrust will ignore report file when either AIRR or barcode_report file is given.

Usage

ReadTrust(
  airr_file = NULL,
  barcode_report_file = NULL,
  report_file = NULL,
  verbose = TRUE
)

Arguments

airr_file

character. Path to AIRR file.

barcode_report_file

character. Path to barcode_report file generated by TRUST4.

report_file

character. Path to report file generated by TRUST4.

verbose

logical. Print progress. Default is TRUE.

Value

A VDJ information data.frame

Examples

Run this code
# NOT RUN {
# file paths
airr_file           = system.file('extdata', 'TRUST4_airr.tsv.gz', package = 'TrustVDJ')
barcode_report_file = system.file('extdata', 'TRUST4_barcode_report.tsv.gz', package = 'TrustVDJ')
report_file         = system.file('extdata', 'TRUST4_report.tsv.gz', package = 'TrustVDJ')

# both AIRR and barcode_report
# }
# NOT RUN {
data = ReadTrust(airr_file = airr_file, barcode_report_file = barcode_report_file)
head(data)
# }
# NOT RUN {
# only AIRR
data = ReadTrust(airr_file = airr_file)
head(data)

# only barcode_report
# }
# NOT RUN {
data = ReadTrust(barcode_report_file = barcode_report_file)
head(data)
# }
# NOT RUN {
# only report
data = ReadTrust(report_file = report_file)
head(data)

# }

Run the code above in your browser using DataLab