Hi everyone,
I am working with RNA-seq data analysis. I want to convert transcript counts to gene counts. I have estimate counts of transcript using Kallisto and I want to use tximport R package to get counts for gene instead of transcripts.
Basically, I have an input tsv file like this:
ENST00000431440.2 0
ENST00000390583.1 1
ENST00000390584.1 5.5
ENST00000390585.1 2.5
ENST00000430425.1 0
and I want the output with gene ids in the first column and their counts in the 2nd column.
From the vignettes page of tximport R package here: (https://bioconductor.org/packages/release/bioc/vignettes/tximport/inst/doc/tximport.html#kallisto), I very much got how to do this task using tximport but I am not understanding how to prepare the input object. I got that I have to use this:
txi.kallisto <- tximport(files, type = "kallisto", tx2gene = tx2gene, ignoreAfterBar = TRUE)
but what is files in this command and how can I prepare this input object in my situation. If someone can please help me with this.
TIA
This works for me, maybe you can try it: