Skip to content

Commit

Permalink
Allow arcs-make to accept uncompressed long read files (#156)
Browse files Browse the repository at this point in the history
* Allow uncompressed read files for arcs-long

* Update README.md
  • Loading branch information
lcoombe authored Jan 4, 2023
1 parent 7dcf508 commit af5c037
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 6 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ To run the pipeline in arcs-long mode, run `bin/arcs-make arks-long`. For exampl
arcs-make arcs-long draft=my_scaffolds reads=my_reads z=1000
```

For more info check `bin/arcs-make help`.
The input long reads can be gzipped or uncompressed. For more info check `bin/arcs-make help`.

**Parameters**: To account for the higher error rates in long reads vs linked reads, we suggest starting with the following values:
* `m=8-10000`
Expand Down Expand Up @@ -130,6 +130,8 @@ arcs-make arks-long draft=my_scaffolds reads=my_reads k=20 j=0.05
* `l=4`
* `a=0.3`

The input long reads can be gzipped or uncompressed.

## Simulating pseudo-linked reads from long reads for `--arks-long` and `--arcs-long` modes

![Pseudo-linked read simulation](arcs-long_pseudo-linked-reads.png)
Expand Down
38 changes: 33 additions & 5 deletions bin/arcs-make
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,41 @@ draft=draft
reads=reads

# Find the complete long read file name
fastq=$(shell test -f $(reads).fq.gz && echo "true")
fasta=$(shell test -f $(reads).fa.gz && echo "true")
ifeq ($(fastq), true)
fastq_gz=$(shell test -f $(reads).fq.gz && echo "true")
fastq=$(shell test -f $(reads).fq && echo "true")
fastq_long=$(shell test -f $(reads).fastq && echo "true")
fastq_gz_long=$(shell test -f $(reads).fastq.gz && echo "true")

fasta_gz=$(shell test -f $(reads).fa.gz && echo "true")
fasta=$(shell test -f $(reads).fa && echo "true")
fasta_long=$(shell test -f $(reads).fasta && echo "true")
fasta_gz_long=$(shell test -f $(reads).fasta.gz && echo "true")

ifeq ($(fastq_gz), true)
long_reads=$(reads).fq.gz
endif
ifeq ($(fasta), true)
ifeq ($(fastq), true)
long_reads=$(reads).fq
endif
ifeq ($(fastq_long), true)
long_reads=$(reads).fastq
endif
ifeq ($(fastq_gz_long), true)
long_reads=$(reads).fastq.gz
endif

ifeq ($(fasta_gz), true)
long_reads=$(reads).fa.gz
endif
ifeq ($(fasta), true)
long_reads=$(reads).fa
endif
ifeq ($(fasta_long), true)
long_reads=$(reads).fasta
endif
ifeq ($(fasta_gz_long), true)
long_reads=$(reads).fasta.gz
endif

# tigmint Parameters
minsize=2000
Expand Down Expand Up @@ -117,7 +144,8 @@ help:
@echo " General Options:"
@echo ""
@echo " draft draft name [draft]. File must have .fasta or .fa extension"
@echo " reads read name [reads]. File must have .fastq.gz or .fq.gz extension"
@echo " reads read name [reads]. File must have .fastq.gz or .fq.gz extension."
@echo " File can be uncompressed (.fastq, .fq) when using arcs-long or arks-long modes."
@echo " time logs time and memory usage to file for main steps (Set to 1 to enable logging)"
@echo ""
@echo " bwa Options:"
Expand Down

0 comments on commit af5c037

Please sign in to comment.