Question: Help in tximport
0
gravatar for Tania
2.1 years ago by
Tania120
Tania120 wrote:

Hello everyone I am doing tximport one file by one then pass them to edgeR dgelist, and I feel this is wrong:

samples <- read.table(file.path("pathhere/salmon", "samples.txt"), header = FALSE)
files <- file.path("path here/", "salmon", samples$V1, "quant.sf")
names(files) <- paste0("sample", 1:20)
tx2gene <- read.csv(file.path("pathhere/salmon", "tx2gene.csv"))
txi.salmon1 <- tximport(files[1], type = "salmon", tx2gene = tx2gene, ignoreTxVersion = TRUE)
write.csv(txi.salmon1$counts, "spquant1.counts")
txi.salmon2 <- tximport(files[2], type = "salmon", tx2gene = tx2gene, ignoreTxVersion = TRUE)
write.csv(txi.salmon2$counts, "spquant2.counts")

Any help how can I Read all my files and use in tximport directly, tried this but not working:

txi_salmon <- tximport(files = files, type = "salmon", txOut = FALSE, tx2gene = tx2gene)reading in files with read_tsv
tximport rnaseq • 1.5k views
ADD COMMENTlink modified 2.1 years ago by WouterDeCoster42k • written 2.1 years ago by Tania120
1
gravatar for Sharon
2.1 years ago by
Sharon460
Sharon460 wrote:

Using "files" this works with me:

txi.salmon <- tximport(files, type = "salmon", tx2gene = tx2gene, ignoreTxVersion = TRUE)
ADD COMMENTlink written 2.1 years ago by Sharon460

Thanks Sharon. That works

ADD REPLYlink written 2.1 years ago by Tania120
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1112 users visited in the last hour