Skip to main content

Sample TCRs according to VJ gene usage frequency

Project description

tcrsampler

Sample TCRs according to VDJ gene usage frequency

Build Status Coverage Status PyPI version

Install

pip install tcrsampler

Example

import os
import pandas as pd
from tcrsampler.sampler import TCRsampler
t = TCRsampler()
fn= os.path.join('tcrsampler' ,'tests', 'pmbc_mixcr_example_data.txt')
t.clean_mixcr(filename = fn)
t.build_background(stratify_by_subject = True, use_frequency = True)
t.sample([['TRBV9*01','TRBJ2-7*01', 2],['TRBV7-7*01', 'TRBJ2-4*01', 4] ], depth = 1, use_frequency = True)
[['CASSRTGSLADEQYF', 'CASSATGVVSAQYF'],
 ['CASSLGQAARGIQYF', 'CASSLGQAARGIQYF', 'CASSLGQAARGIQYF', 'CASSLGQAARGIQYF']]

Download Default Background

python -c "from tcrsampler.setup_db import install_all_next_gen; install_all_next_gen(dry_run = False)"

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

tcrsampler-0.1.8.tar.gz (414.1 kB view details)

Uploaded Source

Built Distribution

tcrsampler-0.1.8-py3-none-any.whl (435.7 kB view details)

Uploaded Python 3

File details

Details for the file tcrsampler-0.1.8.tar.gz.

File metadata

  • Download URL: tcrsampler-0.1.8.tar.gz
  • Upload date:
  • Size: 414.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.41.0 CPython/3.8.3

File hashes

Hashes for tcrsampler-0.1.8.tar.gz
Algorithm Hash digest
SHA256 90fc8aa4af3159b6788ce9696186a6520be8d92ea7be58c1c7cb5773c06e6bde
MD5 f5b6a5e1edb3cbdeda49c6de48d2ccf0
BLAKE2b-256 379fac1a808d93441ef487f1a5d54a631267b7d2985af6271779a89b5ef2c969

See more details on using hashes here.

File details

Details for the file tcrsampler-0.1.8-py3-none-any.whl.

File metadata

  • Download URL: tcrsampler-0.1.8-py3-none-any.whl
  • Upload date:
  • Size: 435.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.41.0 CPython/3.8.3

File hashes

Hashes for tcrsampler-0.1.8-py3-none-any.whl
Algorithm Hash digest
SHA256 c97d0ebaef6f1b56e1c7e9adc7121824cacfa8195328374ffa713c01de7b7438
MD5 7c4b7af54a6adc330eec310d31e18ccc
BLAKE2b-256 7c1702bfd77176d27babde25acc4a65b401aac246059e2779395fbd56931c473

See more details on using hashes here.

Supported by

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