2

I'm pretty new to bioinformatics and I'm trying to decompress a fastq.gz file to convert it into .bam (I'm trying to later analyze this transcriptomic data with DESeq2). I'm in the very beginning of decompressing the file using Jupyter notebooks and cannot make it- Here's the command line I'm using and the error:

In [2] gzip -d /Users/mfp/RNAdata/transcriptome-mcgirr/SRR11476490/CAE4_S34_R1_001.fastq.gz

---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
Input In [2], in <cell line: 1>()
----> 1 gzip -d /Users/mfp/RNAdata/transcriptome-mcgirr/SRR11476490/CAE4_S34_R1_001.fastq.gz

NameError: name 'd' is not defined

Any idea on what I am doing wrong? (Honestly, it can be everything).

DPM
  • 845
  • 7
  • 33

1 Answers1

2

You should use !gzip -d /Users/mfp/RNAdata/transcriptome-mcgirr/SRR11476490/CAE4_S34_R1_001.fastq.gz with a ! before your command. gzip is a binary executable provided by your distribution, which you usually call from a shell or command line. Jupyter's default behaviour is to parse your commands as python statements. Since your command was not a valid python statement, you got an error.

When you prefix your command with !, it is passed to your operating system's shell instead, which is what you wanted in the first place.

You can read the documentation here.

asdf
  • 1,006
  • 1
  • 9