First look exercise answers

From 22126
Revision as of 16:23, 19 March 2024 by WikiSysop (talk | contribs) (Created page with " <H2> Solutions </H2> Illumina data: 1. <pre> cd </pre> 2. <pre> mkdir first_look/ </pre> 3. <pre> cp /data/shared/exercises/first_look/reads.fastq.gz . </pre> 4. <pre> zless -S reads.fastq.gz </pre> 5. <pre> zcat /data/shared/exercises/first_look/reads.fastq.gz |wc -l </pre> 1000 lines so 1000/4 250 sequences. 1. <pre> tar xvfz /data/shared/exercises/first_look/pairedReads.tar.gz </pre> 2. <pre> head ERR243038_1.fastq ERR243038_2.fastq </pre>...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Solutions


Illumina data: 1.

cd 


2.

mkdir first_look/

3.

cp /data/shared/exercises/first_look/reads.fastq.gz .

4.

 zless -S reads.fastq.gz  


5.

 zcat /data/shared/exercises/first_look/reads.fastq.gz  |wc -l 

1000 lines

so 1000/4 250 sequences.

1.

tar xvfz /data/shared/exercises/first_look/pairedReads.tar.gz

2.

head ERR243038_1.fastq ERR243038_2.fastq
grep @ERR243038  ERR243038_1.fastq |head 
grep -m 10  @ERR243038  ERR243038_1.fastq 

the output is:

@ERR243038.1 HS4_09359:1:1101:1072:21612#33/1
@ERR243038.2 HS4_09359:1:1101:1076:69021#33/1
@ERR243038.3 HS4_09359:1:1101:1081:60568#33/1
@ERR243038.4 HS4_09359:1:1101:1086:81871#33/1
@ERR243038.5 HS4_09359:1:1101:1086:82800#33/1
@ERR243038.6 HS4_09359:1:1101:1090:45168#33/1
@ERR243038.7 HS4_09359:1:1101:1091:34108#33/1
@ERR243038.8 HS4_09359:1:1101:1096:7235#33/1
@ERR243038.9 HS4_09359:1:1101:1099:66333#33/1
@ERR243038.10 HS4_09359:1:1101:1101:32746#33/1


grep  @ERR243038  ERR243038_1.fastq  |sed "s/\/1//g" |head 

3.

grep  @ERR243038  ERR243038_1.fastq  |sed "s/\/1//g" > human_1.headers
grep  @ERR243038  ERR243038_2.fastq  |sed "s/\/2//g" > human_2.headers

4.

head human_1.headers
head human_2.headers
paste human_1.headers human_2.headers 
diff human_1.headers human_2.headers