Created
January 23, 2019 19:55
-
-
Save wflynny/1d206aa36c194b170e2bf54595d83d13 to your computer and use it in GitHub Desktop.
Cellranger count snippets (version 2)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Some universal variables | |
NCELLS=6000 | |
OUTPUT_NAME="nice-name" | |
FASTQ_DIR="/path/to/fastqs" | |
REFERENCE_GENOME="/path/to/reference_dir" | |
[[ -z "${PBS_NUM_PPN}" ]] && NCORES=20 || NCORES=${PBS_NUM_PPN} | |
# When reads look like: | |
# sample-name_S?_L00?_R1_001.fastq.gz | |
# sample-name_S?_L00?_R2_001.fastq.gz | |
# sample-name_S?_L00?_I1_001.fastq.gz | |
SAMPLE_NAME="sample-name" | |
cellranger count \ | |
--sample="${SAMPLE_NAME}" \ | |
--id="${OUTPUT_NAME}" \ | |
--transcriptome="${REFERENCE_GENOME}" \ | |
--fastqs="${FASTQ_DIR}" \ | |
--localcores="${NCORES}" \ | |
--expect-cells="${NCELLS}" \ | |
--disable-ui || exit 1 | |
# When reads look like: | |
# sample-name-1_S?_L00?_R1_001.fastq.gz | |
# sample-name-1_S?_L00?_R2_001.fastq.gz | |
# sample-name-1_S?_L00?_I1_001.fastq.gz | |
# ... | |
# sample-name-n_S?_L00?_R1_001.fastq.gz | |
# sample-name-n_S?_L00?_R2_001.fastq.gz | |
# sample-name-n_S?_L00?_I1_001.fastq.gz | |
SAMPLE_LIST="sample-name-1,sample-name-2,...,sample-name-n" | |
SAMPLE_NAME="sample-combined" | |
set -x; cellranger count \ | |
--id="${SAMPLE_NAME}" \ | |
--transcriptome="${REFERENCE_GENOME}" \ | |
--fastqs="${FASTQ_DIR}" \ | |
--expect-cells="${NCELLS}" \ | |
--localcores="${NCORES}" \ | |
--sample="${SAMPLE_LIST}" \ | |
--disable-ui || exit 1 | |
# When reads look like: | |
# sample-name_index1_S?_L00?_R1_001.fastq.gz | |
# sample-name_index1_S?_L00?_R2_001.fastq.gz | |
# sample-name_index1_S?_L00?_I1_001.fastq.gz | |
... | |
# sample-name_indexn_S?_L00?_R1_001.fastq.gz | |
# sample-name_indexn_S?_L00?_R2_001.fastq.gz | |
# sample-name_indexn_S?_L00?_I1_001.fastq.gz | |
INDEX_LIST="index1,...,indexn" | |
SAMPLE_NAME="sample-name" | |
cellranger count \ | |
--id="${SAMPLE_NAME}" \ | |
--transcriptome="${INDEX}" \ | |
--fastqs="${FASTQ_PATH}" \ | |
--expect-cells="${NCELLS}" \ | |
--localcores="${NCORES}" \ | |
--indices=${INDEX_LIST} \ | |
--disable-ui || exit 1 | |
# When reads look like: | |
# sample-name_index1_S?_L00?_R1_001.fastq.gz | |
# sample-name_index1_S?_L00?_R2_001.fastq.gz | |
# sample-name_index1_S?_L00?_I1_001.fastq.gz | |
... | |
# sample-name_indexn_S?_L00?_R1_001.fastq.gz | |
# sample-name_indexn_S?_L00?_R2_001.fastq.gz | |
# sample-name_indexn_S?_L00?_I1_001.fastq.gz | |
# read-I1_si-AGGGCGGT_lane-001-chunk-001.fastq.gz | |
# read-I1_si-AGGGCGGT_lane-002-chunk-000.fastq.gz | |
# read-I1_si-AGGGCGGT_lane-003-chunk-003.fastq.gz | |
# read-I1_si-AGGGCGGT_lane-004-chunk-002.fastq.gz | |
... | |
# read-I2_si-AGGGCGGT_lane-001-chunk-001.fastq.gz | |
# read-I2_si-AGGGCGGT_lane-002-chunk-000.fastq.gz | |
# read-I2_si-AGGGCGGT_lane-003-chunk-003.fastq.gz | |
# read-I2_si-AGGGCGGT_lane-004-chunk-002.fastq.gz | |
... | |
# read-RA_si-AGGGCGGT_lane-001-chunk-001.fastq.gz | |
# read-RA_si-AGGGCGGT_lane-002-chunk-000.fastq.gz | |
# read-RA_si-AGGGCGGT_lane-003-chunk-003.fastq.gz | |
# read-RA_si-AGGGCGGT_lane-004-chunk-002.fastq.gz | |
INDEX_LIST="AGGGCGGT,..." | |
LANE_LIST="1,2,..." | |
SAMPLE_NAME="sample-name" | |
cellranger count \ | |
--id="${SAMPLE_NAME}" \ | |
--transcriptome="${INDEX}" \ | |
--fastqs="${FASTQ_PATH}" \ | |
--expect-cells="${NCELLS}" \ | |
--localcores="${NCORES}" \ | |
--indices=${INDEX_LIST} \ | |
--lanes=${LANE_LIST} \ | |
--disable-ui || exit 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment