使用 Channel 處理 CSV 檔案
🔹 讀取 CSV 檔案
Channel.fromPath('samplesheet.csv')
.splitCsv(header: true)
.view()🔹 搭配 map 處理資料
map 處理資料Channel.fromPath('samplesheet.csv')
.splitCsv(header: true)
.map { row -> tuple(row.sample_id, file(row.fastq)) }
.set { sample_ch }🔹 於 Process 中使用
Last updated