Question: CS 4329 Introduction to bioinformatics. All code must be written in C++ (C++ was also used in CS1, CS2, and CS3). You should submit The
CS 4329 Introduction to bioinformatics.
All code must be written in C++ (C++ was also used in CS1, CS2, and CS3). You should submit
The source codes.
A document showing the output for test cases.
Put all the individual files in one single folder and compress the folder. Upload the compressed folder. Files
should include your first and last names.
1. Implement a C++ function to compute the score of a multiple sequence alignment using Entropy method
(incorporate gaps) and also output the profile of the alignment. Note that your function should be able
detect the number of sequences and the alignment length in the multiple alignment. The alignment
should be read from a text file. Note that pX log2pX is 0 if pX is 0. [100 points]
Test Case 1:
AAA
ACC
ACG
ACT
Output should be
Alignment profile:
A 4 1 1
T 0 0 1
G 0 0 1
C 0 3 1
- 0 0 0
Entropy score is 2.811
Test Case 2:
AAACC
ACG
ACOutput
should be
Alignment profile:
A 4 1 0
T 0 0 0
G 0 0 1
C 0 3 1
- 0 0 2
Entropy score is 2.311
Test Case 3:
GGGCGGTAA
GGGAA
Output should be
Alignment profile:
A 0 0 0 2 2
T 0 0 1 0 0
G 3 3 2 0 0
C 0 0 0 1 0
- 0 0 0 0 1
Entropy score is 2.755
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
