# ANSWER SHEET — Exercise 2

**Name and surname:** Michal Piecuch  
**Student id:** s32484  
**Course:** Basics of Bioinformatics (PBIO 2026/2027), PJATK  
**Exercise:** 2 (English) — Bioinformatic databases in practice

---

## [Task 1]

```python
def get_complement(dna_seq: str) -> str:
    """Returns the complementary DNA strand (A<->T, C<->G)."""
    trans_table = str.maketrans("ACGTUacgtuNn", "TGCAAaccaaNn")
    return dna_seq.translate(trans_table)


user_sequence = input("Enter DNA sequence: ").strip()
complementary_dna = get_complement(user_sequence)

print("Complementary strand (3'->5'): ", complementary_dna)
print("Reverse complement   (5'->3'): ", complementary_dna[::-1])
```

---

## [Task 2]

**Protein sequence:**

```text
MYSFVSEEIGTLIVNSVLLFLAFVVFLLVTLAILTALRLCAYCCNIVNVSLVKPSFYVYSRVKNLNSSRVPDLLV
```

Translated from Reading Frame +1 of the 227 bp viral nucleic acid, yielding a full 75-amino-acid peptide with zero premature stop codons.

---

## [Task 3]

**Full Scientific Name:** **Severe acute respiratory syndrome coronavirus 2** (SARS-CoV-2)

The 75-aa sequence matches the Envelope small membrane protein (E protein) of Severe acute respiratory syndrome coronavirus 2 (NCBI Taxonomy ID: 2697049, Betacoronavirus) across the non-redundant protein database (`nr`).

---

## [Task 4]

**Alignment of Virus_1, Virus_2, and Virus_3:**

```text
Query range 1: 1 to 75
Query     1  MYSFVSEEIGTLIVNSVLLFLAFVVFLLVTLAILTALRLCAYCCNIVNVSLVKPSFYVYSRVKNLNSSRVPDLLV  75
Virus_2   1  .......................LL......................V...........................  75
Virus_3   1  ........................LLF.A......V.LF....................................  75
```

**Interpretation:**

- **Virus_1 vs Virus_2:** 96.00% sequence identity (72 of 75 matches) with 3 substitutions: V24L, V25L, and N48V.
- **Virus_1 vs Virus_3:** 90.67% sequence identity (68 of 75 matches) with 7 substitutions: V25L, F26L, L27F, V29A, A36V, R38L, and L39F.
- **Biological interpretation:** Both terminal ends (residues 1 to 23 and 49 to 75) are 100% conserved across all three viruses. All sequence variations are located in the central hydrophobic transmembrane pore region (residues 24 to 40), where conservative hydrophobic exchanges preserve the ion channel pore.
- **Evolutionary relationship:** Virus_1 is much closer to Virus_2 (96.0% identity) than to Virus_3 (90.7% identity).

---

## [Task 5]

**Similarity Matrix:** **BLOSUM62**

Identified from the `params` section of the single-file JSON report, with default gap penalties of 11 for existence and 1 for extension.

---

## [Task 6]

**Jalview Alignment Visualization:**

*(Screenshot embedded in DOCX / PDF report)*

The JalviewJS visualization shows 100% sequence conservation in yellow across the N-terminal and C-terminal ends, with visible drops in conservation and multi-letter consensus representation across the transmembrane region (columns 24 to 29 and 36 to 39) and at residue 48.

---

## [Task 7]

- **Molecule of the Month (May 2024):** CFTR (Cystic Fibrosis Transmembrane Conductance Regulator)
- **Associated Disease:** Cystic Fibrosis (mukowiscydoza)

---

## [Task 8]

- **Amino acid name:** Phenylalanine
- **Three-letter abbreviation:** PHE
- **One-letter abbreviation:** F
- **Position in chain:** 508
- **Standard notation:** PHE508 (commonly written as p.Phe508del or delta F508)

The deletion of Phenylalanine at position 508 destabilizes the CFTR protein. Endoplasmic reticulum quality-control systems in lung cells recognize the misfolded channel and destroy it before it reaches the cell surface.

---

## [Task 9]

**Type of Inheritance (OMIM #219700):** **Autosomal recessive** (AR)

In the OMIM database for CFTR (Entry #219700), the Phenotype-Gene Relationships table documents the mode of inheritance as Autosomal recessive. Symptoms develop only when both copies of the gene carry pathogenic mutations.

---

## [Task 10]

**Selected Diagram:** **a**

**Justification:** Diagram "a" illustrates autosomal recessive inheritance. Two healthy carrier parents (genotype Aa) have a 25% chance of an affected child (aa), a 50% chance of carrier children (Aa), and a 25% chance of an unaffected child (AA). Diagram "b" depicts autosomal dominant inheritance, where an affected parent passes the condition to 50% of the offspring.

---

## [Task 11]

**Correct Answer:** **2. c.1521_1523del**

In ClinVar (Variation ID: 7105), the classic cystic fibrosis mutation is an in-frame deletion of three nucleotides (CTT), designated `c.1521_1523del`, which removes codon 508 (Phenylalanine) without disrupting the remaining reading frame.

---

## [Task 12]

**dbSNP Identifier (rsID):** **rs113993960**

The reference SNP cluster identifier linked directly from ClinVar variation 7105 is `rs113993960`, located on chromosome 7 (GRCh38 coordinates 117559591-117559594).

---

## [Task 13]

- **PMID:** 2570460
- **Title:** Identification of the cystic fibrosis gene: genetic analysis
- **Authors:** Kerem B, Rommens JM, Buchanan JA, Markiewicz D, Cox TK, Chakravarti A, Buchwald M, Tsui LC
- **Journal:** Science (September 8, 1989, volume 245, issue 4922, pages 1073-1080)
- **Percentage of disease cases:** Approximately 70% (~70% of CF mutant chromosomes worldwide)

---

## [Task 14]

**Function of Neuroglobin (UniProt ID: `Q9NPG2`, `NGB_HUMAN`):**

- Protects neuronal and retinal tissues from ischemic stroke, hypoxia, and reperfusion injury.
- Promotes oxygen delivery to mitochondria in active brain cells under hypoxic stress.
- Scavenges reactive oxygen and reactive nitrogen species, including nitric oxide.
- Acts as a nitrite reductase in its deoxy form to generate NO, slowing down cell respiration and preventing apoptosis.

**Role of the Heme Group:**
Contains an iron-protoporphyrin IX (protoheme) group coordinated by distal His64 and proximal His96. The central iron atom reversibly binds diatomic gases (O2, CO, NO) and undergoes reversible redox reactions (Fe2+ and Fe3+) needed for oxygen storage and antioxidant activity.

---

## [Task 15]

**3D Structure of Human Neuroglobin (PDB ID: 1OJ6):**

*(Screenshot embedded in DOCX / PDF report)*

**Identified Secondary Structures:**

- **Alpha-helices:** The main structural element, forming a classic all-alpha globin fold of 8 alpha-helices (A through H) that make up 70% to 75% of the protein.
- **Turns and loops:** Flexible segments that connect the alpha-helices around the central heme pocket.
- **Beta-sheets:** Completely absent (0%). Neuroglobin contains zero beta-strands.

---

## [Task 16]

**Organism with Neuroglobin Most Similar to Human:** **Pan troglodytes** (Chimpanzee)

**Comparative Sequence Identity vs Human (151 aa):**

- *Pan troglodytes* (Chimpanzee): 151 of 151 identical residues (**100.00% identity**, 0 substitutions)
- *Gorilla gorilla gorilla* (Gorilla): 150 of 151 identical residues (99.34% identity, 1 substitution: Glu2Asp)
- *Sus scrofa* (Pig): 145 of 151 identical residues (96.03% identity, 6 substitutions)
- *Panthera leo* (Lion): 144 of 151 identical residues (95.36% identity, 7 substitutions)
- *Acinonyx jubatus* (Cheetah): 143 of 151 identical residues (94.70% identity, 8 substitutions)
- *Rattus norvegicus* (Brown rat): 143 of 151 identical residues (94.70% identity, 8 substitutions)
- *Mus musculus* (House mouse): 142 of 151 identical residues (94.04% identity, 9 substitutions)
- *Canis lupus dingo* (Dingo): 155 residues (divergent C-terminal extension, less than 92% identity)

---

## Step-by-Step Practical Guide

### Task 1: DNA Complement Script

1. Read the user input string and strip out any surrounding whitespace.
2. Build a translation table mapping A to T and C to G (handling both uppercase and lowercase characters).
3. Call the translate method to create the complementary strand.
4. Slice with `[::-1]` to print the reverse complement in the standard 5' to 3' orientation.

### Task 2: Viral DNA Translation (NCBI BLASTX)

1. Open NCBI BLAST at blast.ncbi.nlm.nih.gov and select the **blastx** tab.
2. Paste the 227 bp viral sequence into the Query box with Genetic Code set to Standard (1).
3. Note the codon count: 227 nucleotides divided by 3 gives 75 complete codons, leaving 2 untranslated nucleotides (TA) at the 3' end.
4. Look at the reading frames: Frame +1 starts with ATG (Methionine) at position 1 and runs 75 residues without hitting any stop codons. Frames +2 and +3 stop early at codons 9 and 14, and all reverse frames have multiple stop codons.
5. Run the search against nr (or align against reference YP_009724392.1) to confirm the 75-aa sequence.

### Task 3: Virus Identification (NCBI BLASTP)

1. On the NCBI BLAST homepage, click **Protein BLAST** (blastp).
2. Paste the 75-aa protein sequence from Task 2 into the Query box.
3. Select the **Non-redundant protein sequences (nr)** database.
4. Click the blue **BLAST** button.
5. In the Descriptions table, locate the **Scientific Name** column (as prompted in the task hint).
6. Read the entry: **Severe acute respiratory syndrome coronavirus 2** (SARS-CoV-2).

### Task 4: Pairwise BLAST Alignment of Three Viruses

1. Open NCBI blastp and check **Align two or more sequences**.
2. Paste Virus_1 (the 75-aa sequence from Task 2) into the Query box with a FASTA header.
3. Paste Virus_2 and Virus_3 into the Subject box in FASTA format.
4. Click **BLAST** to run the alignment.
5. Go to the **Alignments** tab on the results page.
6. Set the Alignment view dropdown to **Flat query-anchored with dots for identities** and set line length to 120.
7. Copy the alignment text and note the substitutions in the transmembrane region.

### Task 5: Similarity Matrix from the JSON Report

1. On the Task 4 BLAST results page, open the **Download All** menu in the upper right.
2. Select and download the **Single-file JSON** report.
3. Open the downloaded file in a text editor.
4. Scroll to the `params` section near the top.
5. Find the `matrix` parameter, which states **BLOSUM62**.

### Task 6: JalviewJS Multiple Alignment

1. From the Task 4 results page, open **Download All** and choose **FASTA (aligned clusters)**.
2. Go to jalview.org and launch **JalviewJS** in the browser.
3. Drag the downloaded FASTA file directly into the Jalview window.
4. Inspect the conservation row: observe 100% yellow bars on both ends and dips in conservation in the middle.
5. Take a screenshot of the window for the report.

### Task 7: RCSB PDB Molecule of the Month

1. Open rcsb.org in your browser.
2. Click **Learn** in the navigation bar and select **Molecule of the Month**.
3. Scroll down to the entry for May 2024.
4. Read the headline and summary to find **CFTR** and its link to **Cystic Fibrosis**.

### Task 8: Amino Acid Deletion in CFTR

1. Scroll down the May 2024 article to the structural explanation of CFTR folding.
2. Find the 3D diagram showing the red arrow pointing to the deleted amino acid.
3. Read the text describing the mutation: Phenylalanine at position 508 (PHE, F, position 508).
4. Note that losing this residue prevents proper folding, leading to endoplasmic reticulum degradation.

### Task 9: OMIM Mode of Inheritance

1. Open omim.org and search for entry number **219700** or "Cystic Fibrosis".
2. Scroll to the **Phenotype-Gene Relationships** table.
3. In the Inheritance column for the CFTR gene record, read **Autosomal recessive** (AR).

### Task 10: Pedigree Diagram Selection

1. Compare the two pedigree diagrams in the assignment sheet.
2. Recall that an autosomal recessive condition shows unaffected carrier parents (Aa) having an affected child (aa) with a 25% recurrence risk.
3. Diagram "a" shows this recessive inheritance pattern, while diagram "b" depicts dominant transmission from an affected parent.
4. Select diagram **a**.

### Task 11: ClinVar Variant Search

1. Open ncbi.nlm.nih.gov/clinvar.
2. In the search box, enter `Phe508 CFTR` (no spaces between letters and numbers).
3. Click on the top result for Variation ID **7105**.
4. Read the HGVS cDNA name listed on the page: **`c.1521_1523del`**.
5. Select option **2**.

### Task 12: dbSNP Identifier Lookup

1. On the ClinVar page for variation 7105, look at the **Links** panel on the right side.
2. Click the link to **dbSNP**.
3. Read the Reference SNP cluster ID at the top: **`rs113993960`**.

### Task 13: Science 1989 Paper in PubMed

1. In ClinVar or OMIM, scroll to the literature citations for CFTR.
2. Find the 1989 Science article on the discovery of the cystic fibrosis gene.
3. Click PMID **2570460** to open the abstract on PubMed.
4. Read the abstract to confirm the author list (Kerem B et al.) and the finding that the Phe508 deletion accounts for about 70% of CF chromosomes.

### Task 14: UniProt Neuroglobin Function

1. Open uniprot.org and search for `neuroglobin human` or accession `Q9NPG2`.
2. Open the **Function** tab to read about oxygen delivery to neurons, neuroprotection during stroke, and free radical scavenging.
3. Open the **Cofactor** and **Sites** sections to examine the protoheme group and its bis-histidyl coordination.

### Task 15: PDB 3D Structure Analysis

1. Go to rcsb.org and search for PDB ID **`1OJ6`**.
2. Click **3D View** to launch the interactive viewer.
3. View the cartoon ribbon representation colored by secondary structure.
4. Count the 8 alpha-helices wrapped around the red heme group, and notice the total lack of beta-sheet arrows.
5. Save a clean screenshot for the report.

### Task 16: MAFFT Phylogenetic Tree

1. Open the MAFFT server at mafft.cbrc.jp/alignment/server/index.html.
2. Paste the mammalian neuroglobin sequences into the input area.
3. Click **Submit** with default parameters to calculate the alignment.
4. Click the **Tree** tab on the results page.
5. Leave default settings (Neighbor-Joining) and click **Go!**.
6. Click **View tree in Phylo.io** to view the interactive tree.
7. Observe that *Pan troglodytes* (Chimpanzee) shares the exact same terminal branch with *Homo sapiens* with branch distance 0, confirming 100% identity.
