Package: neofox
NeoFox - NEOantigen Feature tOolboXNeoFox annotates neoantigen candidate sequences with published neoantigen features.For a detailed documentation, please check outhttps://neofox.readthedocs.ioIf you use NeoFox, please cite the following publication:Franziska Lang, Pablo Riesgo-Ferreiro, Martin Löwer, Ugur Sahin, Barbara Schrörs,NeoFox: annotating neoantigen candidates with neoantigen features, Bioinformatics, Volume 37, Issue 22, 15 November 2021, Pages 4246–4247,https://doi.org/10.1093/bioinformatics/btab344Table of Contents1 Implemented neoantigen features2 NeoFox requirements3 Usage from the command line4 Input data5 Output data1 Implemented Neoantigen FeaturesNeoFox covers the following neoantigen features and prediction algorithms:NameReferenceDOIMHC I binding affinity/rank score (netMHCpan-v4.1)Reynisson et al, 2020, Nucleic Acids Researchhttps://doi.org/10.4049/jimmunol.1700893MHC II binding affinity/rank score (netMHCIIpan-v4.0)Reynisson et al, 2020, Nucleic Acids Researchhttps://doi.org/10.1111/imm.12889MixMHCpred score v2.2  §Bassani-Sternberg et al., 2017, PLoS Comp Bio; Gfeller, 2018, J Immunol.https://doi.org/10.1371/journal.pcbi.1005725,https://doi.org/10.4049/jimmunol.1800914MixMHC2pred score v2.0.2  §Racle et al, 2019, Nat. Biotech. 2019https://doi.org/10.1038/s41587-019-0289-6Differential Agretopicity Index (DAI)Duan et al, 2014, JEM; Ghorani et al., 2018, Ann Oncol.https://doi.org/10.1084/jem.20141308Self-SimilarityBjerregaard et al, 2017, Front Immunol.https://doi.org/10.3389/fimmu.2017.01566IEDB immunogenicityCalis et al, 2013, PLoS Comput Biol.https://doi.org/10.1371/journal.pcbi.1003266Neoantigen dissimilarityRichman et al, 2019, Cell Systemshttps://doi.org/10.1016/j.cels.2019.08.009PHBR-I  §Marty et al, 2017, Cellhttps://doi.org/10.1016/j.cell.2017.09.050PHBR-II  §Marty Pyke et al, 2018, Cellhttps://doi.org/10.1016/j.cell.2018.08.048Generator rateRech et al, 2018, Cancer Immunology Researchhttps://doi.org/10.1158/2326-6066.CIR-17-0559Recognition potential   §Łuksza et al, 2017, Nature; Balachandran et al, 2017, Naturehttps://doi.org/10.1038/nature24473,https://doi.org/10.1038/nature24462VaxrankRubinsteyn, 2017, Front Immunolhttps://doi.org/10.3389/fimmu.2017.01807Priority scoreBjerregaard et al, 2017, Cancer Immunol Immunother.https://doi.org/10.1007/s00262-017-2001-3Tcell predictorBesser et al, 2019, Journal for ImmunoTherapy of Cancerhttps://doi.org/10.1186/s40425-019-0595-zPRIME  §Schmidt et al., 2021, Cell Reports Medicinehttps://doi.org/10.1016/j.xcrm.2021.100194HEX §Chiaro et al., 2021, Cancer Immunology Researchhttps://doi.org/10.1158/2326-6066.CIR-20-0814§ currently not supported for mouse2 NeoFox RequirementsNeoFox depends on the following tools:Python >=3.7, <=3.8R 3.6.0BLAST 2.10.1netMHCpan 4.1netMHCIIpan 4.0MixMHCpred 2.2 (optional)MixMHC2pred 2.0.2 (optional)PRIME 2.0 (optional)Install from PyPI:pip install neofoxOr install from bioconda:conda install bioconda::neofox3 Usage from the command lineNeoFox can be used from the command line as shown below or programmatically (seehttps://neofox.readthedocs.iofor more information).neofox --candidate-file/--json-file neoantigens_candidates.tab/neoantigens_candidates.json --patient-data/--patient-data-json patient_data.txt/patient_data.json --output-folder /path/to/out --output-prefix out_prefix [--patient-id] [--with-table] [--with-json] [--num-cpus] [--affinity-threshold]--candidate-file: tab-separated values table with neoantigen candidates represented by long mutated peptide sequences as describedhere--json-file: JSON file neoantigens in NeoFox model format as  describedhere--patient-id: patient identifier (optional, this will be used if the columnpatientIdentifieris missing in the candidate input file)--patient-data: a table of tab separated values containing metadata on the patient as  describedhere--output-folder: path to the folder to which the output files should be written--output-prefix: prefix for the output files (optional)--with-table: output file in tab-separated format (default)--with-json: output file in JSON format (optional)--num-cpus: number of CPUs to use (optional)--config: a config file with the paths to dependencies as shown below  (optional)--organism: the organism to which the data corresponds. Possible values: [human, mouse]. Default value: human--affinity-threshold: a affinity value (optional) neoantigen candidates with a best predicted affinity greater than or equal than this threshold will be not annotated with features that specifically model
neoepitope recognition. A threshold that is commonly used is 500 nM.The optional config file with the paths to the dependencies can look like this:NEOFOX_REFERENCE_FOLDER=path/to/reference/folder
NEOFOX_RSCRIPT=`which Rscript`
NEOFOX_BLASTP=path/to/ncbi-blast-2.10.1+/bin/blastp
NEOFOX_NETMHCPAN=path/to/netMHCpan-4.1/netMHCpan
NEOFOX_NETMHC2PAN=path/to/netMHCIIpan-4.0/netMHCIIpan
NEOFOX_MIXMHCPRED=path/to/MixMHCpred-2.2/MixMHCpred
NEOFOX_MIXMHC2PRED=path/to/MixMHC2pred-2.0.1/MixMHC2pred_unix
NEOFOX_MAKEBLASTDB=path/to/ncbi-blast-2.8.1+/bin/makeblastdb
NEOFOX_PRIME=/path/to/PRIME-2.0/PRIME4 Input data4.1 Neoantigen candidates in tabular formatThis is an dummy example of a table with neoantigen candidates:genewildTypeXmermutatedXmerpatientIdentifierrnaExpressionrnaVariantAlleleFrequencydnaVariantAlleleFrequencyexternal_annotation_1external_annotation_2BRCA2AAAAAAAAAAAAALAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAPtx7.9420.850.34some_valuesome_valueBRCA2AAAAAAAAAAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAARAAAAAAAAAAAAAPtx7.9420.850.34some_valuesome_valueBRCA2AAAAAAAAAAAAAGAAAAAAAAAAAAAAAAAAAAAAAAAAKAAAAAAAAAAAAAPtx7.9420.850.34some_valuesome_valueBRCA2AAAAAAAAAAAAACAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAPtx7.9420.850.34some_valuesome_valueBRCA2AAAAAAAAAAAAAKAAAAAAAAAAAAAAAAAAAAAAAAAACAAAAAAAAAAAAAPtx7.9420.850.34some_valuesome_valuewhere:gene: the HGNC gene symbolmutatedXmer: the neoantigen candidate sequence, i.e. the mutated amino acid sequence. The mutation should be located in the middle, flanked by 13 amino acid on both sites (IUPAC 1 respecting casing, eg: A)wildTypeXmer: the equivalent non-mutated amino acid sequence (IUPAC 1 respecting casing, eg: A)patientIdentifier: the patient identifierrnaExpression: RNA expression. (optional) (seeNOTE) This value can be in any format chosen by the user (e.g. TPM, RPKM) but it is recommended to be consistent for data that should be compared.rnaVariantAlleleFrequency: the variant allele frequency calculated from the RNA (optional, this will be estimated using thednaVariantAlleleFrequencyif not available)dnaVariantAlleleFrequency: the variant allele frequency calculated from the DNA (optional)NOTE:If rnaExpression is not provided, expression will be estimated by gene expression in a respective TCGA cohort and this value will be used for relevant features. The TCGA cohort to be used for imputation of gene expression needs to be indicated in thetumorTypein the patient data (see below). IftumorTypeis not provided, expression will not be imputed.4.2 Neoantigen candidates in JSON formatBesides tabular format, neoantigen candidates can be provided as a list of neoantigen models in JSON format as shown below. To simplify, only one full neoantigen model is shown:[{"patientIdentifier":"Ptx","gene":"BRCA2","mutation":{"wildTypeXmer":"AAAAAAAAAAAAALAAAAAAAAAAAAA","mutatedXmer":"AAAAAAAAAAAAAFAAAAAAAAAAAAA"}}]4.3 Patient-data formatThis is an dummy example of a patient file:identifiermhcIAllelesmhcIIAllelestumorTypePtxHLA-A*03:01,HLA-A*29:02,HLA-B*07:02,HLA-B*44:03,HLA-C*07:02,HLA-C*16:01HLA-DRB1*03:01,HLA-DRB1*08:01,HLA-DQA1*03:01,HLA-DQA1*05:01,HLA-DQB1*01:01,HLA-DQB1*04:02,HLA-DPA1*01:03,HLA-DPA1*03:01,HLA-DPB1*13:01,HLA-DPB1*04:02HNSCPtyHLA-A*02:01,HLA-A*30:01,HLA-B*07:34,HLA-B*44:03,HLA-C*07:02,HLA-C*07:02HLA-DRB1*04:02,HLA-DRB1*08:01,HLA-DQA1*03:01,HLA-DQA1*04:01,HLA-DQB1*03:02,HLA-DQB1*14:01,HLA-DPA1*01:03,HLA-DPA1*02:01,HLA-DPB1*02:01,HLA-DPB1*04:01HNSCwhere:identifier: the patient identifiermhcIAlleles: comma separated MHC I alleles of the patient for HLA-A, HLA-B and HLA-C. If homozygous, the allele should be added twice.mhcIIAlleles: comma separated  MHC II alleles of the patient for HLA-DRB1, HLA-DQA1, HLA-DQB1, HLA-DPA1 and HLA-DPB1. If homozygous, the allele should be added twice.tumorType: tumour entity in TCGA study abbreviation format (https://gdc.cancer.gov/resources-tcga-users/tcga-code-tables/tcga-study-abbreviations). This field is required for expression imputation and at the moment the following tumor types are supported:5 Output dataThe output data is returned by default in a short wide tab separated values file (--with-table). Optionally, it can be provided in JSON format (--with-json).