---
name: "BuildTrees.py"
section: "1"
platform: "linux"
package: "changeo"
version: "1.3.0-3"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/BuildTrees.py"
---

# BuildTrees.py(1)

Repertoire clonal assignment toolkit (Python 3)

## NAME

BuildTrees.py - Repertoire clonal assignment toolkit (Python 3)

## DESCRIPTION

*/usr/bin/BuildTrees*.py:488: SyntaxWarning: "is" with a literal. Did you mean "=="?

-

  if germline is "":

*/usr/bin/BuildTrees*.py:543: SyntaxWarning: "is" with a literal. Did you mean "=="?

-

  if ngermline is "":

*/usr/bin/BuildTrees*.py:801: SyntaxWarning: "is not" with a literal. Did you mean "!="?

-

  if regions\["cdr3\_imgt"\] is not "" and regions\["cdr3\_imgt"\] is not None:

*/usr/bin/BuildTrees*.py:827: SyntaxWarning: "is not" with a literal. Did you mean "!="?

-

  elif regions\["fwr3\_imgt"\] is not "" and regions\["fwr3\_imgt"\] is not None:

usage: BuildTrees.py \[--version\] \[-h\] **-d** DB\_FILES \[DB\_FILES ...\]

- \[--outdir OUT\_DIR\] \[--outname OUT\_NAME\] \[--log LOG\_FILE\]

  \[--failed\] \[--format {airr,changeo}\] \[--collapse\] \[--ncdr3\] \[--nmask\] \[--md META\_DATA \[META\_DATA ...\]\] \[--clones TARGET\_CLONES \[TARGET\_CLONES ...\]\] \[--minseq MIN\_SEQ\] \[--sample SAMPLE\_DEPTH\] \[--append APPEND \[APPEND ...\]\] \[--igphyml\] \[--nproc NPROC\] \[--clean {none,all}\] \[--optimize {n,r,l,lr,tl,tlr}\] \[--omega {e,ce,e,e,ce,e,e,ce,ce,ce}\] \[-t {e,ce}\] \[--motifs MOTIFS\] \[--hotness HOTNESS\] \[--oformat {tab,txt}\] \[--nohlp\] \[--asr ASR\]

Converts TSV files into IgPhyML input files

### help:

- **--version**

  show program's version number and exit

- **-h**, **--help**

  show this help message and exit

### standard arguments:

- **-d** DB\_FILES \[DB\_FILES ...\]

  A list of tab delimited database files. (default: None)

- **--outdir** OUT\_DIR

  Specify to changes the output directory to the location specified. The input file directory is used if this is not specified. (default: None)

- **--outname** OUT\_NAME

  Changes the prefix of the successfully processed output file to the string specified. May not be specified with multiple input files. (default: None)

- **--log** LOG\_FILE

  Specify to write verbose logging to a file. May not be specified with multiple input files. (default: None)

- **--failed**

  If specified create files containing records that fail processing. (default: False)

- **--format** {airr,changeo}

  Specify input and output format. (default: airr)

### sequence processing arguments:

- **--collapse**

  If specified, collapse identical sequences before exporting to fasta. (default: False)

- **--ncdr3**

  If specified, remove CDR3 from all sequences. (default: False)

- **--nmask**

  If specified, do not attempt to mask split codons. (default: False)

- **--md** META\_DATA \[META\_DATA ...\]

  List of fields to containing metadata to include in output fasta file sequence headers. (default: None)

- **--clones** TARGET\_CLONES \[TARGET\_CLONES ...\]

  List of clone IDs to output, if specified. (default: None)

- **--minseq** MIN\_SEQ

  Minimum number of data sequences. Any clones with fewer than the specified number of sequences will be excluded. (default: 1)

- **--sample** SAMPLE\_DEPTH

  Depth of reads to be subsampled (before deduplication). (default: **-1**)

- **--append** APPEND \[APPEND ...\]

  List of columns to append to sequence ID to ensure uniqueness. (default: None)

### IgPhyML arguments (see igphyml -h for details):

- **--igphyml**

  Run IgPhyML on output? (default: False)

- **--nproc** NPROC

  Number of threads to parallelize IgPhyML across. (default: 1)

- **--clean** {none,all}

  Delete intermediate files? none: leave all intermediate files; all: delete all intermediate files. (default: none)

- **--optimize** {n,r,l,lr,tl,tlr}

  Optimize combination of topology (t) branch lengths (l) and parameters (r), or nothing (n), for IgPhyML. (default: lr)

- **--omega** {e,ce,e,e,ce,e,e,ce,ce,ce}

  Omega parameters to estimate for FWR,CDR respectively: e = estimate, ce = estimate + confidence interval (default: e,e)

- **-t** {e,ce}

  Kappa parameters to estimate: e = estimate, ce = estimate + confidence interval (default: e)

- **--motifs** MOTIFS

  Which motifs to estimate mutability. (default: WRC\_2:0,GYW\_0:1,WA\_1:2,TW\_0:3,SYC\_2:4,GRS\_0:5)

- **--hotness** HOTNESS

  Mutability parameters to estimate: e = estimate, ce = estimate + confidence interval (default: e,e,e,e,e,e)

- **--oformat** {tab,txt}

  IgPhyML output format. (default: tab)

- **--nohlp**

  Don't run HLP model? (default: False)

- **--asr** ASR

  Ancestral sequence reconstruction interval (0-1). (default: **-1**)

### output files:

-

  \<folder\>

-

  folder containing fasta and partition files for each clone.

-

  lineages

-

  successfully processed records.

-

  lineages-fail

-

  database records failed processing.

-

  igphyml-pass

-

  parameter estimates and lineage trees from running IgPhyML, if specified

### required fields:

-

  sequence\_id, sequence, sequence\_alignment, germline\_alignment\_d\_mask or germline\_alignment, v\_call, j\_call, clone\_id, v\_sequence\_start

## AUTHOR

 This manpage was written by Nilesh Patra for the Debian distribution and\
  can be used for any other usage of the program.
