Write a perl program that asks a user for a motif like qdsv


Do the following exercises and submit by the due date. Submit one word doc file with all your code pasted into it (no need for output snap shots) and also submit all the .pl files (all in one zip file would be great).

1) Perhaps the most common thing we do in Bioinformatics is look for domains and motifs in sequences. Write a Perl program that asks a user for a motif (like QDSV or MKPL) and returns a message saying whether the motif is found in the sequence or not.

Program requirements:

a) Use at least one subroutine, the more you compartmentalize your code the better though!

b) Assume the protein sequence is stored in a file in FASTA format. So you are going to prompt the user for this file, make sure it opened and read, and then proceed to read the file\sequence into your program.

c) Use strict.

d) Use indentations and comments in your code.

2) Activity of a certain enzyme was measured in extracts from brain, heart and lung. In each tissue, the activity was measured several times, giving the following results (in arbitrary units):

brain: 65, 69, 70, 63, 70, 68.
heart: 102, 95, 98, 110.
lung: 112, 115, 113, 109, 95, 98, 100.

Write a program that calculates and prints the following information for each of the tissues:
a) number of measurements
b) average enzyme activity

Write a subroutine for each piece of information above (i.e. a subroutine that finds the number of measurements and returns it, a sub that finds the average and returns it). The main part of your program should call the subroutines for each data set (brain, heart and lung) and print out the results to the screen.

Program requirements:
a) Store each of the data sets into an array.
b) Pass each array to the subroutines, see lecture notes on how to pass by reference.

c) You should only have ONE sub for number of measurements and ONE for the average. But you need to CALL each of those two subs 3 times (for each of the data sets). Do not create a sub for each data set, because that defeats the purpose of a subroutine! Remember subs are meant to simplify and allow for reuse of code.

Solution Preview :

Prepared by a verified Expert
Programming Languages: Write a perl program that asks a user for a motif like qdsv
Reference No:- TGS01355537

Now Priced at $35 (50% Discount)

Recommended (95%)

Rated (4.7/5)