Skip to content

Argument parsing, usage statement, and small improvements for countKmers#11

Open
standage wants to merge 4 commits into
atifrahman:masterfrom
standage:count-cli
Open

Argument parsing, usage statement, and small improvements for countKmers#11
standage wants to merge 4 commits into
atifrahman:masterfrom
standage:count-cli

Conversation

@standage

@standage standage commented Feb 15, 2019

Copy link
Copy Markdown

I made a few changes to the countKmers script for my own use, and thought they might be useful for others as well.

  • added option parsing so that users can configure cores, paths, etc from the command line without modifying the script
  • added a usage statement so users can see options by running ./countKmers -h
  • added an option for users to specify the FASTQ file extension; also, it autodetects whether the extension includes .gz or not and dynamically determines whether to use zcat or cat, again so users don't have to modify the script

I also updated README.md to reflect these changes, and the fact that Jellyfish 2 is a suitable alternative to the modified version of Jellyfish bundled with HAWK which seems to be giving some users issues.

Comment thread README
@@ -1,72 +0,0 @@
HAWK version 0.9.8

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file is redundant with README.md, and some parts are out of date. Better to just drop it.

Comment thread README.md
Comment thread supplements/countKmers
CATCMD="bunzip2 -c"
else
CATCMD=cat
fi

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here is where the compression is autodetected.

Comment thread supplements/countKmers
jellyfishDir=/home/atif/jellyfish-Hawk/bin #directory where jellyfish is installed
sortDir=/home/atif/coreutils/deps/bin #directory where parallel sort is installed
#!/usr/bin/env bash
set -eo pipefail

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's helpful to halt execution if something goes wrong. Makes it easier to isolate the point of failure if it doesn't just try to keep going to the next sample.

@standage

Copy link
Copy Markdown
Author

Rolled back the text about Jellyfish 2.

@atifrahman

Copy link
Copy Markdown
Owner

Thank you so much for your modifications! Incorporated a few. We are working on a few things. We will take care of the rest once that's done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants