alexyermanos / Platypus

R package for the analysis of single-cell immune repertoires
GNU General Public License v3.0
40 stars 16 forks source link

Human genome in function for GSEA And AIRR_to_VGM trim.and.align = T load error #9

Closed leeanapeters closed 2 years ago

leeanapeters commented 2 years ago

Hi there, just wanted to point out that the "species" argument doesn't seem to work for anything other than mouse in the GEX_GO_TERM function unless you modify the function to have org.hs.eg.db listed instead of the mouse genome! Didn't see it listed in the vignette so wanted to point that out for people working with human data.

Thanks for the great package!

Leeana

vickreiner commented 2 years ago

Thanks for pointing this out! We will fix this and push and update as soon as possible!

leeanapeters commented 2 years ago

No problem, thanks for the quick response @vickreiner !

Another unrelated question (happy to post separately) but are you all thinking of including compatibility with the output of TRUST4 (at least for BCR)? I am noticing just the CSV does not work even after conversion to 10x format.

vickreiner commented 2 years ago

Sure, happy to help! TRUST4 support is already implemented via the PlatypusDB_AIRR_to_VGM function in Platypus 3.2.2. (CRAN released this updated just a couple of days ago) For that function please use the output ...airr.tsv (or ...barcode_airr.tsv if it single cell data) files from TRUST4 as input to the AIRR.input argument. In case of large large outputs, the function may return an error. In that case please switch VDJ.combine to FALSE. Please let me know if you encounter any issues with this! Thanks!

leeanapeters commented 2 years ago

Hi @vickreiner, thank you for the help with this! I am encountering an error and am not sure if it is the one you mentioned. It happens with only one sample so I hope it is not a case of large output. [1] "2022-02-10 20:45:33 EST" [1] "2022-02-10 20:45:33 EST" [1] "2022-02-10 20:50:55 EST" Error in substr(curr.barcode$VDJ_sequence_nt_raw, as.numeric(curr.contigs$v_sequence_start[1]), : invalid substring arguments

This is after I've run

VgmTB<- PlatypusDB_AIRR_to_VGM(AIRR.input =TBlist, group.id = c("T1D", "T1D", "CTL", "CTL"), VDJ.combine = FALSE, trim.and.align = TRUE, filter.overlapping.barcodes.VDJ = FALSE)

I've made lists of the paths to the tsvs or lists of tables of the tsvs loaded into the R environment and get the error either way.

Any help would be much appreciated! And happy to move to a different issue if you'd like to close the GSEA one :)

Thanks

vickreiner commented 2 years ago

Hi Leeana,

this issue stems from the information needed for sequence trimming. Airr.tsv tables from Cellranger come with a couple of numeric columns that indicate the start and end index of a given gene segment (e.g. v_sequence_start, v_sequence_end). TRUST4 does not seem to output any such columns, which is why the function fails. I pushed a new version that issues a warning to the user in this case rather than failing.

Despite this it is still possible to get the trimmed sequence from TRUST4 via MiXCR alignment (which is a little ironic, given that the two are basically competitors). You can use the Platypus_AIRR_to_VGM function with trim.and.align = FALSE

VgmTB<- PlatypusDB_AIRR_to_VGM(AIRR.input =TBlist, group.id = c("T1D", "T1D", "CTL", "CTL"), VDJ.combine = FALSE, trim.and.align = FALSE, filter.overlapping.barcodes.VDJ = FALSE)

and then use the VDJ_call_MIXCR function (see documentation of that for info on how to download MiXCR so that R can access it) to realign and output nucleotide sequences of all Framework and CDR regions. Once pasted together, these yield a full variable region contig.

VgmTB[[1]][[1]] <- VDJ_call_MIXCR(VDJ = VgmTB[[1]][[1]], platypus.version = "v3") (Nested list indexing here, because the PlatypusDB_AIRR_to_VGM function returns a list of VDJ dataframes if VDJ.combine = FALSE. I would always recommend setting VDJ.combine to TRUE for convenience.)

Hope this helps! Best, Victor

vickreiner commented 2 years ago

I pushed a fix to the GEX_GOterm function to ensure that it works with human data as well. Let me know if any issues persist.

https://github.com/alexyermanos/Platypus/blob/master/R/GEX_GOterm.R

Best, Victor

leeanapeters commented 2 years ago

Hey Victor, thank you for the help!

Hopefully last question about the AIRR format and MIXCR.

I made sure to have the mixcr.jar file in my working directory, but I am getting an error.

VgmTB[[1]]<- VDJ_call_MIXCR(VDJ = VgmTB[[1]], mixcr.directory = "G:/BRUSKO_LAB/SINGLE-CELL_DATA_ARCHIVE/NS1998/out/count/sct objects/mixcr.jar",platypus.version = "v3", species = "hsa", simplify = TRUE) Windows system detected Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Microsoft Windows [Version 10.0.18363.2037] (c) 2019 Microsoft Corporation. All rights reserved.

G:\BRUSKO_LAB\SINGLE-CELL_DATA_ARCHIVE\NS1998\out\count\sct objects>Error in file(file, "rt") : cannot open the connection In addition: Warning message: In file(file, "rt") :

Error in file(file, "rt") : cannot open the connection

Do you have any recommendations?

Thanks again,

Leeana


From: Victor Kreiner @.> Sent: Thursday, February 10, 2022 11:18 PM To: alexyermanos/Platypus @.> Cc: Peters,Leeana D @.>; Author @.> Subject: Re: [alexyermanos/Platypus] Human genome in function for GSEA And AIRR_to_VGM trim.and.align = T load error (Issue #9)

[External Email]

Hi Leeana,

this issue stems from the information needed for sequence trimming. Airr.tsv tables from Cellranger come with a couple of numeric columns that indicate the start and end index of a given gene segment (e.g. v_sequence_start, v_sequence_end). TRUST4 does not seem to output any such columns, which is why the function fails. I pushed a new version that issues a warning to the user in this case rather than failing.

Despite this it is still possible to get the trimmed sequence from TRUST4 via MiXCR alignment (which is a little ironic, given that the two are basically competitors). You can use the Platypus_AIRR_to_VGM function with trim.and.align = FALSE

VgmTB<- PlatypusDB_AIRR_to_VGM(AIRR.input =TBlist, group.id = c("T1D", "T1D", "CTL", "CTL"), VDJ.combine = FALSE, trim.and.align = FALSE, filter.overlapping.barcodes.VDJ = FALSE)

and then use the VDJ_call_MIXCR function (see documentation of that for info on how to download MiXCR so that R can access it) to realign and output nucleotide sequences of all Framework and CDR regions. Once pasted together, these yield a full variable region contig.

VgmTB[[1]][[1]] <- VDJ_call_MIXCR(VDJ = VgmTB[[1]][[1]], platypus.version = "v3") (Nested list indexing here, because the PlatypusDB_AIRR_to_VGM function returns a list of VDJ dataframes if VDJ.combine = FALSE. I would always recommend setting VDJ.combine to TRUE for convenience.)

Hope this helps! Best, Victor

— Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_alexyermanos_Platypus_issues_9-23issuecomment-2D1035871494&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=nXvCJXhrqx7BOesRpa5jGUjpKqmM7_3v3z0ViinC65adoZp-jX8TqPp04h808vSJ&s=Cuen2x7uUAumZmZdnhHDCdfDznkDkN3er00C7nFMxSo&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_APDFEKF5A3AH4N6RAUPIKV3U2SEYZANCNFSM5NYTVM2A&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=nXvCJXhrqx7BOesRpa5jGUjpKqmM7_3v3z0ViinC65adoZp-jX8TqPp04h808vSJ&s=7oWGmEmCsJy8tBx9SgYEiFxAgwzjWa1HYWakI4QrdEk&e=. Triage notifications on the go with GitHub Mobile for iOShttps://urldefense.proofpoint.com/v2/url?u=https-3A__apps.apple.com_app_apple-2Dstore_id1477376905-3Fct-3Dnotification-2Demail-26mt-3D8-26pt-3D524675&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=nXvCJXhrqx7BOesRpa5jGUjpKqmM7_3v3z0ViinC65adoZp-jX8TqPp04h808vSJ&s=hMCgmWaKtn44d2wZgieTCWCNIR6bTvkbcA5-1SETtkc&e= or Androidhttps://urldefense.proofpoint.com/v2/url?u=https-3A__play.google.com_store_apps_details-3Fid-3Dcom.github.android-26referrer-3Dutm-5Fcampaign-253Dnotification-2Demail-2526utm-5Fmedium-253Demail-2526utm-5Fsource-253Dgithub&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=nXvCJXhrqx7BOesRpa5jGUjpKqmM7_3v3z0ViinC65adoZp-jX8TqPp04h808vSJ&s=RhZSaY1CfeypEdyhTW5Zww93lgCzcCRCI8GtypHtbnk&e=. You are receiving this because you authored the thread.Message ID: @.***>

vickreiner commented 2 years ago

Hi,

that looks like R did not find MiXCR at the expected location. When specifying the MiXCR directory, please do not include the actual /mixcr.jar file in the path. Alternatively you can not specify this directory and R will just use the current working directory as default.

VgmTB[[1]]<- VDJ_call_MIXCR(VDJ = VgmTB[[1]],platypus.version = "v3", species = "hsa", simplify = TRUE)

If this should not work, it could be due to access issues to the mixcr path (e.g. if working on a server). In that case please try to move the mixcr.jar file to a local path to which you have full access.

Sorry that for the complication. I will specify this further in the documentation and add an error catcher for this.

Best, Victor!

leeanapeters commented 2 years ago

Sorry I should have mentioned that I tried without the path specified and with the path leading to mixcr.jar but not including the actual file and I still receive the error.


From: Victor Kreiner @.> Sent: Friday, February 11, 2022 2:25 PM To: alexyermanos/Platypus @.> Cc: Peters,Leeana D @.>; Author @.> Subject: Re: [alexyermanos/Platypus] Human genome in function for GSEA And AIRR_to_VGM trim.and.align = T load error (Issue #9)

[External Email]

Hi,

that looks like R did not find MiXCR at the expected location. When specifying the MiXCR directory, please do not include the actual /mixcr.jar file in the path. Alternatively you can not specify this directory and R will just use the current working directory as default.

VgmTB[[1]]<- VDJ_call_MIXCR(VDJ = VgmTB[[1]],platypus.version = "v3", species = "hsa", simplify = TRUE)

Sorry that for the complication. I will specify this further in the documentation and add an error catcher for this.

Best, Victor!

— Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_alexyermanos_Platypus_issues_9-23issuecomment-2D1036542126&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=TZY7BgEa7f8bzR8VxmSnbvStwL2q-Xv9rlXAugh1xmUHBPYy1LB48jZPML4659GD&s=fmexnmbmacOdO_Q_s0cDIMdwPanahcH88NH_fNryLMg&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_APDFEKETE3R63S5Q6PXLAT3U2VPDHANCNFSM5NYTVM2A&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=TZY7BgEa7f8bzR8VxmSnbvStwL2q-Xv9rlXAugh1xmUHBPYy1LB48jZPML4659GD&s=O6IUtQDNaFAJcKHXLc-Au441RlSC8Sk_2wbdqvjZyHo&e=. Triage notifications on the go with GitHub Mobile for iOShttps://urldefense.proofpoint.com/v2/url?u=https-3A__apps.apple.com_app_apple-2Dstore_id1477376905-3Fct-3Dnotification-2Demail-26mt-3D8-26pt-3D524675&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=TZY7BgEa7f8bzR8VxmSnbvStwL2q-Xv9rlXAugh1xmUHBPYy1LB48jZPML4659GD&s=8tX1LIJLu_lmPCthd4iqX1q7JNnM6f5OrSFDHj8HpbY&e= or Androidhttps://urldefense.proofpoint.com/v2/url?u=https-3A__play.google.com_store_apps_details-3Fid-3Dcom.github.android-26referrer-3Dutm-5Fcampaign-253Dnotification-2Demail-2526utm-5Fmedium-253Demail-2526utm-5Fsource-253Dgithub&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=TZY7BgEa7f8bzR8VxmSnbvStwL2q-Xv9rlXAugh1xmUHBPYy1LB48jZPML4659GD&s=Pl8MIlrjyo5fRD2gP3fRBpbXJq_f8MSU5n_8nnfQmkc&e=. You are receiving this because you authored the thread.Message ID: @.***>

leeanapeters commented 2 years ago

Here is the traceback in case it is helpful!

Error in file(file, "rt") : cannot open the connection 3. file(file, "rt") 2. utils::read.table(file = "tempmixcrhc.out.txt", sep = "\t", header = T, stringsAsFactors = FALSE, fill = TRUE) 1. VDJ_call_MIXCR(VDJ = VgmTB[[1]], platypus.version = "v3", species = "hsa", simplify = TRUE)


From: Peters,Leeana D @.> Sent: Friday, February 11, 2022 2:32 PM To: alexyermanos/Platypus @.>; alexyermanos/Platypus @.> Cc: Author @.> Subject: Re: [alexyermanos/Platypus] Human genome in function for GSEA And AIRR_to_VGM trim.and.align = T load error (Issue #9)

Sorry I should have mentioned that I tried without the path specified and with the path leading to mixcr.jar but not including the actual file and I still receive the error.


From: Victor Kreiner @.> Sent: Friday, February 11, 2022 2:25 PM To: alexyermanos/Platypus @.> Cc: Peters,Leeana D @.>; Author @.> Subject: Re: [alexyermanos/Platypus] Human genome in function for GSEA And AIRR_to_VGM trim.and.align = T load error (Issue #9)

[External Email]

Hi,

that looks like R did not find MiXCR at the expected location. When specifying the MiXCR directory, please do not include the actual /mixcr.jar file in the path. Alternatively you can not specify this directory and R will just use the current working directory as default.

VgmTB[[1]]<- VDJ_call_MIXCR(VDJ = VgmTB[[1]],platypus.version = "v3", species = "hsa", simplify = TRUE)

Sorry that for the complication. I will specify this further in the documentation and add an error catcher for this.

Best, Victor!

— Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_alexyermanos_Platypus_issues_9-23issuecomment-2D1036542126&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=TZY7BgEa7f8bzR8VxmSnbvStwL2q-Xv9rlXAugh1xmUHBPYy1LB48jZPML4659GD&s=fmexnmbmacOdO_Q_s0cDIMdwPanahcH88NH_fNryLMg&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_APDFEKETE3R63S5Q6PXLAT3U2VPDHANCNFSM5NYTVM2A&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=TZY7BgEa7f8bzR8VxmSnbvStwL2q-Xv9rlXAugh1xmUHBPYy1LB48jZPML4659GD&s=O6IUtQDNaFAJcKHXLc-Au441RlSC8Sk_2wbdqvjZyHo&e=. Triage notifications on the go with GitHub Mobile for iOShttps://urldefense.proofpoint.com/v2/url?u=https-3A__apps.apple.com_app_apple-2Dstore_id1477376905-3Fct-3Dnotification-2Demail-26mt-3D8-26pt-3D524675&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=TZY7BgEa7f8bzR8VxmSnbvStwL2q-Xv9rlXAugh1xmUHBPYy1LB48jZPML4659GD&s=8tX1LIJLu_lmPCthd4iqX1q7JNnM6f5OrSFDHj8HpbY&e= or Androidhttps://urldefense.proofpoint.com/v2/url?u=https-3A__play.google.com_store_apps_details-3Fid-3Dcom.github.android-26referrer-3Dutm-5Fcampaign-253Dnotification-2Demail-2526utm-5Fmedium-253Demail-2526utm-5Fsource-253Dgithub&d=DwMCaQ&c=sJ6xIWYx-zLMB3EPkvcnVg&r=zrOHRUbMoMSIoz7l5zvpSifsOzkwEbhjSJrU7vQObK8&m=TZY7BgEa7f8bzR8VxmSnbvStwL2q-Xv9rlXAugh1xmUHBPYy1LB48jZPML4659GD&s=Pl8MIlrjyo5fRD2gP3fRBpbXJq_f8MSU5n_8nnfQmkc&e=. You are receiving this because you authored the thread.Message ID: @.***>

vickreiner commented 2 years ago

Thanks for the error trace. This is R complaining that I did not find a MiXCR output. Given your previous output that just means that MiXCR did not run. Can you open your CMD and navigate to the directory where mixcr.jar is located cd "G:\[add full path here]\sct objects" if that works, try starting mixcr using: java -jar mixcr.jar If that returns the mixcr documentation and no error, than mixcr is able to run properly.

mourisl commented 2 years ago

Hi, TRUST4's developer here. Leeana opened an issue in TRUST4, and I tracked the leads to here :).

The v_sequence_start, v_sequence_end information is optional in AIRR specification, so I did not output that information to keep the output minimal. But the sequence trimming information can be read out in the mandatory v_cigar, j_cigar field in the AIRR format. I think the value of the first soft clipping symbol in v_cigar plus 1 corresponds to the v_sequence_start number. For j_sequence_end, it can be read from the j_cigar string last soft clipping symbol, and then (the sequence length - the last soft clipping number) will be j_sequence_end. Hope this helps.

vickreiner commented 2 years ago

Hi, Thanks for getting in touch! That sounds great. I will check back with the AIRR guidelines too and implement this into Platypus.

Also thanks for TRUST4 as a whole. I have been testing it out on a couple of published datasets and so far I am very impressed!

vickreiner commented 2 years ago

Added @mourisl suggestions to Platypus_AIRR_to_VGM(). Trim.and.align = T now works also with TRUST4 input

leeanapeters commented 2 years ago

Hi Victor, thanks for the updates!

I am still encountering the error for accessing mixcr in R even though I can get mixcr to run in the same directory thru the terminal. Sorry for pestering you! Do you know of any way I can get around this?

Error in file(file, "rt") : cannot open the connection 3. file(file, "rt") 2. utils::read.table(file = "tempmixcrhc.out.txt", sep = "\t", header = T, stringsAsFactors = FALSE, fill = TRUE) 1. VDJ_call_MIXCR(VDJ = VgmTB[[1]], platypus.version = "v3", species = "hsa", simplify = TRUE)

vickreiner commented 2 years ago

Hi Leeana, sorry for the very late reply. Have you tried this possibly on another machine?

MaryGoAround commented 1 year ago

Hi

I need help please

I have two PBMCs

I have 10x 5' GEX, TCR, BCR data for that on which I run TRUST4 and I am using TRUST_barcode_airr.tsv files as an input

I noticed for each kit separately (TCR or BCR not both) I can run the code but having the data together returns error

>   VDJ.out.directory.list <- list()
  >   VDJ.out.directory.list_T[[1]] <- c("/data/TRUST4-master/TRUST_PN0340_0001_TCR_S1_L001_R2_001_barcode_airr.tsv") # sample1
  >   VDJ.out.directory.list_T[[2]] <- c("/data/TRUST4-master/TRUST_PN0340_0002_TCR_S4_L001_R2_001_barcode_airr.tsv") # sample2
  >   VDJ.out.directory.list_B[[1]] <- c("/data/TRUST4-master/TRUST_PN0340_0001_BCR_S2_L001_R2_001_barcode_airr.tsv") # sample1
  Error in VDJ.out.directory.list_B[[1]] <- c("/data/TRUST4-master/TRUST_PN0340_0001_BCR_S2_L001_R2_001_barcode_airr.tsv") : 
    object 'VDJ.out.directory.list_B' not found
  >   VDJ.out.directory.list_B[[2]] <- c("/data/TRUST4-master/TRUST_PN0340_0002_BCR_S5_L001_R2_001_barcode_airr.tsv") # sample2
  Error in VDJ.out.directory.list_B[[2]] <- c("/data/TRUST4-master/TRUST_PN0340_0002_BCR_S5_L001_R2_001_barcode_airr.tsv") : 
    object 'VDJ.out.directory.list_B' not found
  >   VDJ.out.directory.list_GEX[[1]] <- c("/data/TRUST4-master/TRUST_PN0340_0001_GEX_S3_L001_R2_001_barcode_airr.tsv") # sample1
  Error in VDJ.out.directory.list_GEX[[1]] <- c("/data/TRUST4-master/TRUST_PN0340_0001_GEX_S3_L001_R2_001_barcode_airr.tsv") : 
    object 'VDJ.out.directory.list_GEX' not found
  >   VDJ.out.directory.list_GEX[[2]] <- c("/data/TRUST4-master/TRUST_PN0340_0002_GEX_S6_L001_R2_001_barcode_airr.tsv") # sample2
  Error in VDJ.out.directory.list_GEX[[2]] <- c("/data/TRUST4-master/TRUST_PN0340_0002_GEX_S6_L001_R2_001_barcode_airr.tsv") : 
    object 'VDJ.out.directory.list_GEX' not found

But for one kit that works

VDJ.out.directory.list_T <- list()
  >   VDJ.out.directory.list_T[[1]] <- c("/data/TRUST4-master/TRUST_PN0340_0001_TCR_S1_L001_R2_001_barcode_airr.tsv") # sample1
  >   VDJ.out.directory.list_T[[2]] <- c("/data/TRUST4-master/TRUST_PN0340_0002_TCR_S4_L001_R2_001_barcode_airr.tsv") # sample2
  >   VgmT<- PlatypusDB_AIRR_to_VGM(AIRR.input =VDJ.out.directory.list_T, group.id = c("tcr1", "tcr2"), VDJ.combine = FALSE, trim.and.align = FALSE, filter.overlapping.barcodes.VDJ = FALSE)
  > VgmT
  $VDJ
  $VDJ[[1]]
  orig_barcode             barcode sample_id group_id clonotype_id celltype Nr_of_VDJ_chains Nr_of_VJ_chains
  1  AAAAAAACAGAATTTC s1_AAAAAAACAGAATTTC        s1     bcr1 Undetermined   T cell                1               0
  2  AAAAAACCAACGAACC s1_AAAAAACCAACGAACC        s1     bcr1 Undetermined   T cell                0               1
  3  AAAAAACTATACCATC s1_AAAAAACTATACCATC        s1     bcr1 Undetermined   T cell                0               1
  4  AAAAAATTCAACCACT s1_AAAAAATTCAACCACT        s1     bcr1 Undetermined   T cell                1               0

Any idea please? Shall I make one separate object for each kit? Then how to merge that?

Thanks for any idea