Skip to main content

TCRcloud is a TCR repertoire visualization and comparison tool

Project description

GitHub last commit GitHub release (latest by date) PyPI PyPI - Python Version PyPI - Wheel License

TCRcloud

TCRcloud is a TCR repertoire visualization and comparison tool

Instalation

TCRcloud is written in python and can be installed from PyPI using pip:

$ pip3 install TCRcloud

Currently it is only compatible with linux-64 and osx-64 because one of the dependencies used is also only compatible with those operating systems. It does work on WSL if you want to use Windows.

TCRcloud uses the AIRR Data Commons API and needs AIRR compliant data as input

Usage

To create a word cloud

$ TCRcloud cloud AIRR_rearrangements_file.tsv

By default TCRcloud colours the CDR3 based on the Vgene but you can provide a json file that atributes colours in Hex format to specific sequences:

{
"#FF0000":["CAASITGNQFYF","CAVREDGTSGSARQLTF"],
"#0000FF":["CAVMDSNYQLIW"]
}

The sequences not in the file will be coloured grey.

To use your custom colours for the word cloud

$ TCRcloud cloud AIRR_rearrangements_file.tsv -c colours.json

To create a word cloud without a legend

$ TCRcloud cloud AIRR_rearrangements_file.tsv -l False

To create a radar plot comparing diversity metrics

$ TCRcloud radar AIRR_rearrangements_file.tsv

By default TCRcloud uses repertoire_id but you can create a legend with the text you want by providing a json file:

{
"2839362682105696746-242ac113-0001-012":"Twin 2A",
"2939134772391776746-242ac113-0001-012":"Twin 2B"
}  

To create a radar plot with your desired legend

$ TCRcloud radar AIRR_rearrangements_file.tsv -c legend.json

To create a radar plot without a legend

$ TCRcloud radar AIRR_rearrangements_file.tsv -l False

Using TCRcloud you can download rearragements files from the AIRR compliant databases based on AIRR repertoire metadata files

To download AIRR rearrangements files

$ TCRcloud download AIRR_repertoire_file.json

TCRcloud provides some test data to experiment the tool. The data is one twin pair from the monozygotic twins study from the Mark Davis lab (DOI: 10.1038/ncomms11112)

To download the test data repertoire file

$ TCRcloud testdata

After having the testdata.airr.json file you can use the download function included in TCRcloud to get the matching rearragements file.

Examples:

TRA CDR3 word cloud alpha

TRB CDR3 word cloud beta

TRG CDR3 word cloud gamma

TRD CDR3 word cloud delta

Diversity comparison

Comparing here the αβ repertoire from one twin pair from the monozygotic twins study from the Mark Davis lab (DOI: 10.1038/ncomms11112)

radar

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

TCRcloud-1.2.1.tar.gz (11.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

TCRcloud-1.2.1-py3-none-any.whl (14.3 kB view details)

Uploaded Python 3

File details

Details for the file TCRcloud-1.2.1.tar.gz.

File metadata

  • Download URL: TCRcloud-1.2.1.tar.gz
  • Upload date:
  • Size: 11.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.8.10

File hashes

Hashes for TCRcloud-1.2.1.tar.gz
Algorithm Hash digest
SHA256 a008186297e63e8e56e0ad60a0f760e7cd90729336f86571d837a6e1d8cb935d
MD5 0c3a819ff07d869873f64b60535c99a5
BLAKE2b-256 16e0767ae1ffba7f6eb5dc48dbe749f19cf6530d17a76fad46ee71db10ac9ac5

See more details on using hashes here.

File details

Details for the file TCRcloud-1.2.1-py3-none-any.whl.

File metadata

  • Download URL: TCRcloud-1.2.1-py3-none-any.whl
  • Upload date:
  • Size: 14.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.8.10

File hashes

Hashes for TCRcloud-1.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6831917d3f009b17cb1d2ee6db93b224cc056e5e182c324b84415fee06bee87b
MD5 d0f030fc876745923fac4ad5459ebe65
BLAKE2b-256 662a866ca3c85fd0d847e5571dc56c9c4edb002576dc49d06c9878f1b9a0186e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page