Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: STAR mtx conversion when using GeneFull #135

Merged
merged 3 commits into from
Jul 31, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Fixes

- Fixed Kallistobustools workflow [#123](https://github.com/nf-core/scrnaseq/issues/123) by upgrading to nf-core/modules module
- Fixed matrix conversion error when running STAR with --soloFeatures GeneFull [#135](https://github.com/nf-core/scrnaseq/pull/135)

## v2.0.0 - 2022-06-17 "Gray Nickel Beagle"

Expand Down
6 changes: 3 additions & 3 deletions modules/local/mtx_to_h5ad.nf
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ process MTX_TO_H5AD {
barcodes_tsv = "*_alevin_results/alevin/quants_mat_rows.txt"
features_tsv = "*_alevin_results/alevin/quants_mat_cols.txt"
} else if (params.aligner == 'star') {
mtx_matrix = "*.Solo.out/Gene/filtered/matrix.mtx"
barcodes_tsv = "*.Solo.out/Gene/filtered/barcodes.tsv"
features_tsv = "*.Solo.out/Gene/filtered/features.tsv"
mtx_matrix = "*.Solo.out/Gene*/filtered/matrix.mtx.gz"
barcodes_tsv = "*.Solo.out/Gene*/filtered/barcodes.tsv.gz"
features_tsv = "*.Solo.out/Gene*/filtered/features.tsv.gz"
}

//
Expand Down
6 changes: 3 additions & 3 deletions modules/local/mtx_to_seurat.nf
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ process MTX_TO_SEURAT {
barcodes = "*_alevin_results/alevin/quants_mat_rows.txt"
features = "*_alevin_results/alevin/quants_mat_cols.txt"
} else if (params.aligner == 'star') {
matrix = "*.Solo.out/Gene/filtered/matrix.mtx"
barcodes = "*.Solo.out/Gene/filtered/barcodes.tsv"
features = "*.Solo.out/Gene/filtered/features.tsv"
matrix = "*.Solo.out/Gene*/filtered/matrix.mtx.gz"
barcodes = "*.Solo.out/Gene*/filtered/barcodes.tsv.gz"
features = "*.Solo.out/Gene*/filtered/features.tsv.gz"
}

"""
Expand Down
5 changes: 5 additions & 0 deletions modules/local/star_align.nf
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,11 @@ process STAR_ALIGN {
gzip ${prefix}.unmapped_2.fastq
fi

if [ -d ${prefix}.Solo.out ]; then
# Backslashes still need to be escaped (https://github.com/nextflow-io/nextflow/issues/67)
find ${prefix}.Solo.out \\( -name "*.tsv" -o -name "*.mtx" \\) -exec gzip {} \\;
fi

cat <<-END_VERSIONS > versions.yml
"${task.process}":
star: \$(STAR --version | sed -e "s/STAR_//g")
Expand Down