Bioinformatics and Functional Genomics (Wiley, 3rd edition) Solutions to Problems

Jonathan Pevsner,Ph.D. [email protected] Last update: August 15, 2015 Version 1

This document includes solutions to problems for Part I of the book (Chapters 2-7). Separate documents contain solutions to Part II (Chapters 8-14) and Part III (Chapters 15-21).  I welcome teachers to contact me with any comments or questions.  If you find any errors please let me know. Other readers (both students and teachers) would appreciate knowing about them.  Some problems include a solution already given. These are meant to be exercises that give the reader experience in using a method or thinking about a problem.

Table of contents Page Solutions to problems: Chapter 2 2 Solutions to problems: Chapter 3 24 Solutions to problems: Chapter 4 39 Solutions to problems: Chapter 5 60 Solutions to problems: Chapter 6 77 Solutions to problems: Chapter 7 104

Errata Problem 2.8, step 1: Change NCBI36/hg19 to GRCh37/hg19 Problem 13.8: Change E6V to E7V

1 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Solutions to problems: Chapter 2 Access to Sequence Data and Related Information

[2-1] The purpose of this problem is to introduce you to using and related NCBI resources. How many human are bigger than 300,000 daltons? What is the longest human ? There are several different ways to solve these questions. (1) Try to first limit your search to human by using TaxBrowser. From the home page of NCBI select the alphabetical list of resources and find the Taxonomy Browser and the entry for human. Then follow the link to Entrez Protein, where all the results will be limited to human. (2) Enter a command in the format xxxxxx:yyyyyy[molwt] to restrict the output to a certain number of Daltons; for example, 002000:010000[molwt] will select proteins of molecular weight 2,000 to 10,000. (3) As a different approach, search 30000:50000[Sequence Length] (4) You can read more about titin (NP_596869.4), the longest human protein, in an NCBI newsletter (WebLink 2.73). While the average protein has a length of several hundred amino acids, incredibly titin is 34,423 amino acids in length. (5) Explore additional ways to limit Entrez searches by using an NCBI Handbook chapter (http://www.ncbi.nlm.nih.gov/books/NBK44864/) (WebLink 2.74).

Solutions/comments: Here is a screen capture of the Taxonomy Browser page:

2 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Click human (or search for your favorite organism):

On the above page, click the protein link. This allows you to link to proteins that are human. The taxonomy identifier (txid) 9606 corresponds to human.

3 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) On the left sidebar select the molecular weight range from 300,000 (i.e. the minimum sizewe are looking for in this problem) to 6 million (a size larger than the largest human protein):

The result is that there are 2,458 proteins (of which 1,415 are RefSeq proteins) >300,000 daltons.

To see the largest proteins adjust the range (to 3.9 million to 6 million):

Titin is the largest, comprised of over 35,000 amino acids:

4 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [2-2] The purpose of this problem is to obtain information from the NCBI website. The RefSeq accession number of human beta protein is NP_000509. Go to NCBI (http://www.ncbi.nlm.nih.gov/). What is the RefSeq accession number of beta globin protein from the chimpanzee (Pan troglodytes)? (1) There are several different ways to solve this. Try typing chimpanzee globin into the home page of NCBI; or use the Taxonomy Browser to find chimpanzee Entrez entries. (2) HomoloGene (http://www.ncbi.nlm.nih.gov/homologene)(WebLink 2.38) is a great resource to learn about sets of related eukaryotic proteins. Use HomoloGene to find a set of beta including chimpanzee.

Solutions/comments: Entering chimpanzee globin into the NCBI home page leads to results in both Gene and HomoloGene:

The Gene result sorts chimpanzee HBB to the top:

5 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Follow the first entry (HBB) to see the RefSeq accession. In the above screen shot you can also see the accession NC_006478.3. This corresponds to the entire 11 of the chimp (Pan troglodytes isolate Yerkes chimp pedigree #C0471 (Clint) , Pan_troglodytes-2.1.4). You can also follow wthe HomoloGene link:

Here the , beta entry leads you to the accession for the chimp HBB protein:

6 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The answer is XP_508242.1.

[2-3] The purpose of this exercise is to become familiar with the EBI website and how to use it to access information. (1) Visit the site (http://www.ebi.ac.uk/)(WebLink 2.5). Enter hemoglobin beta in the main query box (alternatively use the query human hemoglobin beta). (2) Inspect the reults. Explore the various links to information about pathways, genomes, nucleotide and protein sequences, structures, protein families, and more.

Solutions/comments: Here is the EBI home page:

7 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here is the search result page:

This problem does not call for a more specific solution, but this is a starting point to explore the content, organization and style of the EBI website. One approach is to ask students to spend some minimum amount of time (e.g. 10 minutes or 30 minutes) exploring the beta globin results in this site.

[2-4] Accessing information from BioMart: the beta globin . 8 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) (1) Go to www.ensembl.org and follow the link to BioMart. (2) First choose a database; we will select Ensembl 71. (3) Choose a dataset: Homo sapiens genes (GRCh37.p10). Note the other available datasets. (4) Choose a filter. Here the options include region, gene, transcript event, expression, multispecies comparisons, protein domains, and variation. Select “region”, chromosome 11, and enter 5240000 for the Gene Start (bp) and 5300000 (bp) for the Gene End. (Note that this region spans 60 kilobases and corresponds to chr11:5,240,001-5,300,000.) (5) Choose attributes. Select the following features. Under “Gene” select Ensembl Gene ID and %GC content; under “External” select the external references CCDS ID, HGNC symbol (this is the official gene symbol) and HGNC ID(s). (6) At the top left select “Count.” Currently there are 8 genes matching these criteria. (7) To view these results press “Results.”Note that you can export your results in several formats (including a comma separated values or CSV file) that can be further manipulated (e.g. converted to a BED file).

Solutions/comments: Access BioMart from Ensembl:

Choose a database (Ensembl Genes 81)

Choose a region, as described:

9 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Select attributes, using check boxes:

Click “results” (button at upper left).

[2-5] BioMart: working with lists. The goal of this exercise is to access information in BioMart by uploading a text file listing gene identifiers of interest. Follow the steps from problem 2-4, but for the filter set choose Gene (instead of Region), select ID list limit and adjust the pulldown menu to HGNC symbol, then browse for a text file having a list of gene symbols. See Web Document 2.5 for a text file listing official HGNC symbols for 13 human globin genes (CYGB, HBA1, HBA2, HBB, HBD, HBE1, HBG1, HBG2, HBM, HBQ1, HBZ, MB, NGB). You could also enter these gene symbols manually. For

10 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) attributes choose any set of features that is different than in problem 2-4, so that you can further explore BioMart resources.

Solutions/comments: Paste the following list: CYGB, HBA1, HBA2, HBB, HBD, HBE1, HBG1, HBG2, HBM, HBQ1, HBZ, MB, NGB

Make sure that the pull-down menu is set to “HGNC symbol(s) [e.g. NTN3]” as shown above. Proceed to click the results button.

[2-6] Accessing information from Ensembl. (1) Visit the Ensembl resource for humans (via http://www.ensembl.org/human). (2) In the main search box enter 11:5,240,001-5,300,000. The resulting page displays several panels. At the top, all of chromosome 11 is shown. Where on the chromosome is the region we have selected? In what chromosomal band does this region reside? (3) The next panel shows the region in detail. What is the size of the displayed region, in base pairs? In general, genes encoding olfactory receptors are gamed OR followed by a string of numbers and letters (e.g. OR51F1). Approximately how many olfactory receptor genes flank the 60 kb region we have selected? Can you determine exactly how many ORs are in that region? (4) Next we see the region we selected (11:5240001-5300000). Note that there are horizontal tracks (similar to the UCSC Genome Browser).

Solutions/comments: Be sure to specify the species (human) if you have not done so. Here is the search:

11 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here is the upper portion of the results page:

We can see many olfactory receptor (OR) genes. The question asks exactly how many are in this region. The best approach is to use a table browser (such as the UCSC Table Browser or BioMart) that counts for you, or to use a program such as EDirect that counts and that uses the command line (thus fostering reproducible research since you can share with others the commands you used to get your answer).

12 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [2-7] Accessing information from UCSC. Hemoglobin is a tetramer composed primarily of two alpha globin subunits and two beta globin subunits. Consider alpha globin. There are two related human genes (official gene symbols HBA1 and HBA2). Use the UCSC Genome Browser (http://genome.ucsc.edu/) to determine the length of the intergenic region between the HBA1 and HBA2 genes.

Solutions/comments: You can get an approximate answer visually: enter HBA1 in the UCSC Genome Browser.

Zoom out 10-fold and you will see the adjacent HBA1 and HBA2 genes:

You can drag (hold your cursor just below the ideogram) to find that the distance is about 2,900 base pairs.

13 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) To get a more precise answer use the Table Browser, from the Tool menu:

Set a region encompassing both genes and set the various menus as shown here:

14 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) This is the output (set to all fields).

This is the output (as a BED file). From either of these outputs you can calculate the exact intergenic distance.

For example, take the beginning of one the more 3’ gene (position 226,715) and subtract the end of the more 5’ gene (position 223,599) = 3,116 base pairs.

[2-8] Accessing information from UCSC. What types of repetitive DNA elements occur in the human beta globin gene? The purpose of this exercise is for you to gain familiarity with the UCSC Genome Browser. As a user, you choose which tracks to display. Visit and explore as many as possible. Try to get a sense for the main categories of information offered at the Genome Browser. As you work in the genome browser you may want to switch between builds hg18, hg19, and hg20. To do so, go the the “View” pull-down menu and use “In other genomes (convert).” Follow the following steps. (1) Go to http://genome.ucsc.edu/cgi-bin/hgGateway. Make sure the clade is Mammal, genome is Human, assembly is NCBI36/hg19, and in the “gene” box enter hbb for beta globin. Click Submit. Note that HBB is the official gene symbol for beta globin, but you 15 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) can use the lowercase hbb for this search. Use NCBI Gene (or http://www.genenames.org for the HGNC site) to find the official gene symbol of your favorite gene. (2) Click the “default tracks” button. Note the position you have reached (chromosome 11, spanning 1,606 base pairs close to the beginning of the short or “p” arm of the chromosome). Note the appearance of over a dozen graphical tracks that are horizontally oriented. (3) One of the tracks is “Repeating Elements by Repeatmasker.” There are two black blocks. Right click on the block and select “Full.” Alternatively, scroll down to the section entitled “Variation and Repeats,” locate “RepeatMasker,” and change the pull- down menu setting from “dense” to “full.” Note also that by clicking the blue heading “RepeatMasker” you visit a page describing the RepeatMasker program and its use at the UCSC Genome Browser. (4) View the RepeatMasker output. Choose one answer. a. There are no repetitive elements. b. There is one SINE element and one LINE element. c. There is one LTR and one satellite. d. There is one LINE element and one low complexity element. e. There are well over a dozen repetitive elements.

Solutions/comments: The starting point at UCSC is as follows:

The view of the default tracks:

The view with the RepeatMasker track (at bottom) expanded:

16 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) By inspection answer (d) is correct.

[2-9] Accessing information from the UCSC Table Browser. How many SNPs span the human beta globin gene? To solve this problem, use the UCSC Table Browser. The Table Browser is equally useful as the Genome Browser. Instead of offering visual output, it offers tabular output. Often it is not practical (or accurate) to visually count elements from the Genome Browser. We often want quantitative information about genomic features in some chromosomal region or across the whole genome. This problem asks about single nucleotide polymorphisms (SNPs), which are positions that vary (i.e. exhibit polymorphism) across individuals in a population. Follow the following steps. (1) Start at the HBB region of the UCSC Genome Browser and click the “Tables” tab along the top. Alternatively, you can go to the UCSC website (http://genome.ucsc.edu), and click Tables. Set the clade to Mammal, genome to Human, assembly to NCBI36/hg18, group to Variation and Repeats, track to SNPs(130), table to snp130, and region to position chr11:5203272-5204877. Note that if the position is not already set, you can type hbb into the position box, click “lookup” and the correct position will be entered. (2) To see the answer to this problem, click “summary/statistics.” The item count tells you how many SNPs there are. (3) To see the answer as a table, set the output format to “all fields from selected table,” make sure the “Send output to Galaxy / GREAT” boxes are not checked, and click the “get output” box. The SNPs are shown as a table including chromosome, start, and stop position. (4) Try the various output options, such as a bed file or a custom track. Note that you can output the information as a file saved to your computer.

Solutions/comments: In the group “Variation” the tracks that are currently available include Common SNPs(142):

17 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The problem refers to the SNP database version 130. Over time, the particular databases are frequently updated. For Common SNPs(142), clicking summary/statistics shows there are 37 SNPs across the HBB gene locus.

[2-10] Accessing information from Galaxy. How big is the largest RefSeq gene on human chromosome 21? Solve this problem by using Galaxy. (1) First go to Galaxy (http://usegalaxy.org). Optionally, you can register (under the “User” tab). (2) On the left sidebar, choose “Get Data” then “UCSC Main table browser.” (3) Set the clade (Mammal), genome (Human), assembly (GRCh37 [or try GRCh38]), group (Genes and Gene Prediction Tracks), track (RefSeq Genes), table (RefGene), region (click position then enter “chr21” without the quotation marks) then click “lookup” right next to the position. Under output format choose “BED-browser extensible data” and click the box “Send output to Galaxy.” (4) Optionally, click “summary/statistics” to get a quick look at how many proteins are assigned to chromosome 21. (That answer is currently 636.) (5) At the lower left part of the page, click “get output.” Note that you now have a variety of output options; choose BED and click “Send query to Galaxy.” (6) Galaxy’s central panel informs you that the job is added to the queue. (7) Your data set is available in the history panel to the right. Click the data set header [1: UCSC Main on Human: refGene (chr21:1-46944323)] to see the number of regions and to see the column headers. Click the “eye” icon to see your data in the central panel. (8) Next figure out the size of the genes. First, add a new column. On the left Galaxy panel click “Text Manipulation” then “Compute an expression on every row.” Add the expression c3-c2 to take the end position of each gene and subtract the beginning. For “Round result?” choose “Yes.” Click “Execute.”

18 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) (9) A new data set is created, called “Compute on data 1.” There is a new column 13 with the sizes of all the genes. Go to the left sidebar of Galaxy, click “Filter and Sort,” click “Sort data in ascending or descending order” and choose the query; the column (c13); the flavor (numerical sort); the order (descending); and click Execute. (10) A new data set is created. Click the eye icon to see your spreadsheet in the main Galaxy panel. Your answer is there on the first (top) row. Optionally, go to “Text Manipulation,” select “Cut columns from a table,” and Cut columns (c5,c6,c7,c8,c9,c10,c11,c12). This will clean up your table, making it easier to see column 13 with the gene lengths.

Solutions/comments: Here is the Galaxy home page; I recommend registering and logging in so you can save your work. From the Tools menu (left sidebar) choose Get Data > UCSC Main table browser.

Set the Table Browser entries as follows:

The current total number of genes (652) on this chromosome is shown by clicking the summary/statistics tab: 19 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Click “get ouput” then send query to Galaxy.

Follow the above directions. Your imported data appear in the right sidebar; click the eye icon to see the data in the main display:

20 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) As indicated in the problem’s directions (above), use Tools > Text Manipulation > Compute an expression on every row > add expression c3-c2 (this will take the end position minus the start position of every gene on chromosome 21).

Here is the output: a new file is created (data set 4: compute on data 3) with a new column 13 showing the size of every gene:

21 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Now we need to sort the results on column 13 to see which is the largest gene on chromosome 21. Tools > Filter and sort. Execute.

The answer is that the largest gene is 834,697 base pairs. It is NM_001271534; it is DSCAM. 22 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) 23 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Solutions to problems: Chapter 3 Pairwise Sequence Alignment

For the first problems we will perform pairwise alignments of globins using complementary approaches.

[3-1] Obtain the human HBA and HBB protein sequences. Perform pairwise alignment at the NCBI BLAST website. Then use a comparison tool from the EBI website. Vary the scoring matrix (e.g. try different PAM and BLOSUM matrices) and record the effects on the score, the number of gaps, the percent identity, and the length of the aligned region. For the NCBI BLASTP program note that the output of a pairwise alignment includes a dot matrix view.

Solutions/comments: You can find the HBA1 gene information at NCBI Gene:

From here we can find the RefSeq accession number and sequence of HBA1 protein, and similarly, HBB. They are: >gi|4504347|ref|NP_000549.1| [Homo sapiens] MVLSPADKTNVKAAWGKVGAHAGEYGAEALERMFLSFPTTKTYFPHFDLSHGSAQVKGHGKKVADALTNA VAHVDDMPNALSALSDLHAHKLRVDPVNFKLLSHCLLVTLAAHLPAEFTPAVHASLDKFLASVSTVLTSK YR >gi|4504349|ref|NP_000509.1| [Homo sapiens] MVHLTPEEKSAVTALWGKVNVDEVGGEALGRLLVVYPWTQRFFESFGDLSTPDAVMGNPKVKAHGKKVLG AFSDGLAHLDNLKGTFATLSELHCDKLHVDPENFRLLGNVLVCVLAHHFGKEFTPPVQAAYQKVVAGVAN ALAHKYH

Now let’s align them at NCBI:

24 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here is part of the result, showing the dot matrix view and the description of the result:

25 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Next visit EBI to try a search tool. Go to http://www.ebi.ac.uk/Tools/psa/ to see a list of relevant tools. Choose Water and protein.

Enter the two protein sequences in the FASTA format. Many tools do not accept RefSeq identifiers and therefore it is helpful to have the FASTA formatted sequences available.

Click submit. View the output: ######################################## 26 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) # Program: water # Rundate: Sun 16 Aug 2015 19:32:50 # Commandline: water # -auto # -stdout # -asequence emboss_water-I20150816-193249-0133-48100150-es.asequence # -bsequence emboss_water-I20150816-193249-0133-48100150-es.bsequence # -datafile EBLOSUM62 # -gapopen 10.0 # -gapextend 0.5 # -aformat3 pair # -sprotein1 # -sprotein2 # Align_format: pair # Report_file: stdout ########################################

#======# # Aligned_sequences: 2 # 1: NP_000549.1 # 2: NP_000509.1 # Matrix: EBLOSUM62 # Gap_penalty: 10.0 # Extend_penalty: 0.5 # # Length: 145 # Identity: 63/145 (43.4%) # Similarity: 88/145 (60.7%) # Gaps: 8/145 ( 5.5%) # Score: 293.5 # # #======

NP_000549.1 3 LSPADKTNVKAAWGKVGAHAGEYGAEALERMFLSFPTTKTYFPHF-DLS- 50 |:|.:|:.|.|.|||| :..|.|.|||.|:.:.:|.|:.:|..| ||| NP_000509.1 4 LTPEEKSAVTALWGKV--NVDEVGGEALGRLLVVYPWTQRFFESFGDLST 51

NP_000549.1 51 ----HGSAQVKGHGKKVADALTNAVAHVDDMPNALSALSDLHAHKLRVDP 96 .|:.:||.|||||..|.::.:||:|::....:.||:||..||.||| NP_000509.1 52 PDAVMGNPKVKAHGKKVLGAFSDGLAHLDNLKGTFATLSELHCDKLHVDP 101

NP_000549.1 97 VNFKLLSHCLLVTLAAHLPAEFTPAVHASLDKFLASVSTVLTSKY 141 .||:||.:.|:..||.|...||||.|.|:..|.:|.|:..|..|| NP_000509.1 102 ENFRLLGNVLVCVLAHHFGKEFTPPVQAAYQKVVAGVANALAHKY 146

#------#------

Return to the NCBI. It was:

27 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) At the top left of the BLAST result page click “edit and resubmit” to perform pairwise alignment again. Click “algorithm parameters” to change those settings:

Settings Matrix E value Identities Gaps Default (see above) BLOSUM62 2e-37 63/145 8/145 BLOSUM90 2e-36 63/145 8/145 PAM30 4e-34 65/149 9/149 PAM250 3e-37 63/146 8/146

28 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Using these other scoring matrices has a minimal effect on the results. It is often easier to see large differences when two proteins are more distantly related, or when only a portion of two proteins aligns well.

[3-2] Perform pairwise alignment at the UCSC website. (1) Go to http://genome.ucsc.edu (WebLink 3.13). follow the link to the genome browser, select the hg19 build, and enter a query of hbb. This should direct you to chr11:5,246,696-5,248,301 (a region of 1,606 base pairs encompassing the beta globin gene, HBB. (2) Click the box to set the view to default tracks. (3) Under “Comparative Genomics” select Placental Chain/ Net and set the display to full. By clicking the Placental Chain/Net header you can view a series of options. Set Chains to full view and Nets to full view. Set the species to horse (deselect other species). Click submit. (4) The display now shows human/horse chained alignments and and alignment nets.

Solutions/comments: Visit the UCSC Genome Browser, enter hbb (lower case or upper case). The Comparative Genomics options are here:

Click the header of that track to view more options; deselect all (-key) then select horse, and set chains and nets from pack or dense to full:

29 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Click Submit. The resulting Genome Browser display shows chained alignments and alignment nets.

30 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Click an alignment block to explore. You can click to view the pairwise alignment between human and horse DNA at that region.

31 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [3-3] Perform pairwise alignment using EMBOSS tools via Galaxy and UCSC. In this exercise we will perform global alignment with the EMBOSS package needle and local alignment with the EMBOSS package water. Both of these are available at the Galaxy public web server (along with over 100 other EMBOSS tools). Box 3.9 introduces EMBOSS and explains how to import beta globin (HBB) and alpha globin (HBA2) proteins from the UCSC Table Browser using Galaxy, and to then align them. This history is saved at https://main.g2.bx.psu.edu/u/pevsner/h/pairwise-alignment-via-ucsc-and-emboss (WebLink 3.14). Note that Galaxy is a web-based platform for using hundreds of bioinformatics tools, including next-generation sequence data analysis software. To use it visit http://usegalaxy.org then go to the public server. Be sure to create a username and log in. This will allow you to continue your work over time and at different work stations.

Solutions/comments: Visit the URL given above and the HBA2 and HBB sequences are available, as well as pairwise alignments that are global (“needle”) or local (“water”).

[3-4] View scoring matrices and perform pairwise alignment using R. In this exercise we begin by installing the Biostrings package. Instructions for installing R and RStudio are given in Chapter 2.

32 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) > getwd() # Get the working directory, and use setwd() to # change it to any preferred location > source("http://bioconductor.org/biocLite.R") > biocLite("Biostrings") > library(Biostrings)# Install the Biostrings library > data(BLOSUM50) # load the data for the BLOSUM50 matrix > BLOSUM50[1:4,1:4] # view the first four rows and columns # of this matrix > nw <- pairwiseAlignment(AAString("PAWHEAE"), AAString("HEAGAWGHEE"), substitutionMatrix = BLOSUM50, gapOpening = 0, gapExtension = -8) # create object nw aligning # two amino acid strings with the specified matrix and gap # penalties > nw # view the result. Try repeating this alignment with # different gap penalties and scoring matrices. Biostrings # includes 10 matrices (PAM30 PAM40, PAM70, PAM120, PAM250, # BLOSUM45, BLOSUM50, BLOSUM62, BLOSUM80, and BLOSUM100). > compareStrings(nwdemo) # view the alignment

Solutions/comments: Follow the instructions above to complete this exercise. I recommend that you (and students) install the latest versions of R (from http://r-project.org; follow the CRAN download link) and RStudio (http://www.rstudio.com). Both are free. Use RStudio as the interface for R. I also recommend that students try an introductory R course. Many free, excellent tutorials are available. Try these: http://swirlstats.com https://www.codecademy.com

[3-5] Perform pairwise alignment using Biopython. Python is a freely available programming language. When implemplemented with Biopython it offers a broad range of computational tools (Cock et al., 2009). You will need to install three programs: (1) Python, (2) Numpy (a package for scientific computing with Python), and (3) Biopython (this provides particular bioinformatics applications within the Python framework). The downloads can be obtained from http://www.python.org (WebLink 3.15), http://www.numpy.org/ (WebLink 3.16), and http://biopython.org (WebLink 3.17).If you are working on a PC launch a user-friendly interface called IDLE (Python’s Integrated DeveLopment Environment). For information on installing Biopython, and for a “cookbook” with many basic bioinformatics applications including pairwise alignment,

33 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) visit http://biopython.org/DIST/docs/tutorial/Tutorial.html (WebLink 3.18). Try the following commands; my comments follow a hash (#) and are in green text.

Python 2.7.3 (default, Apr 10 2012, 23:31:26) [MSC v.1500 32 bit (Intel)] on win32 Type "copyright", "credits" or "license()" for more information. >>> from Bio import pairwise2 >>> from Bio.SubsMat import MatrixInfo as matlist >>> matrix = matlist.blosum62 # specify the scoring matrix. >>> gap_open = -10 # set the affine gap penalties >>> gap_extend = -1 >>> hbb = "MVHLTPEEKSAVTALWGKVNVDEVGGEALGRLLVVYPWTQRFFESFGDLSTPDAVMGNP KVKAHGKKVLGAFSDGLAHLDNLKGTFATLSELHCDKLHVDPENFRLLGNVLVCVLAHHF GKEFTPPVQAAYQKVVAGVANALAHKYH" # You can paste these sequences in from your Galaxy session (problem 3-4), or from EBI, NCBI, or Ensembl, or UCSC. >>> hba2 = "MVLSPADKTNVKAAWGKVGAHAGEYGAEALERMFLSFPTTKTYFPHFDLSHGSAQVKGH GKKVADALTNAVAHVDDMPNALSALSDLHAHKLRVDPVNFKLLSHCLLVTLAAHLPAEFT PAVHASLDKFLASVSTVLTSKYR" >>> alns = pairwise2.align.globalds(hbb, hba2, matrix, gap_open, gap_extend) >>> top_aln = alns[0] >>> aln_hbb, aln_hba2, score, begin, end = top_aln >>> print aln_hbb+'\n'+aln_hba2 MVHLTPEEKSAVTALWGKV-- NVDEVGGEALGRLLVVYPWTQRFFESFGDLSTPDAVMGNPKVKAHGKKVLGAFSDGLAHL DNLKGTFATLSELHCDKLHVDPENFRLLGNVLVCVLAHHFGKEFTPPVQAAYQKVVAGVA NALAHKYH MV-LSPADKTNVKAAWGKVGAHAGEYGAEALERMFLSFPTTKTYFPHF-DLSH----- GSAQVKGHGKKV

Solutions/comments: Follow the above protocol; the solution is given. There are many excellent introductions to Python. A good place to start is https://www.python.org, incuding a getting started guide at https://www.python.org/about/gettingstarted/.

[3-6] Using the amino acid explorer tool from NCBI. (1) Visit http://www.ncbi.nlm.nih.gov/Class/Structure/aa/aa_explorer.cgi (WebLink 3.19). (2) Select the Biochemical Properties table. Which amino acid is most abundant? (Is it leucine, at 9.94%?). Use this table to test yourself and make sure you know the one- and three-letter abbreviations for all 20 amino acids, as well as their structures. (2) Is tyrosine a hydrophobic amino acid? To decide, use the Common Substitutions table. Explore

34 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) (a hydrophobic residue), sort the results by hydrophobicity, and see where tyrosine is located. You can also explore the Structure and Chemistry table.

Solutions/comments: This site has a variety of interesting resources:

As shown here in this partial output of a table, leucine is the most abundant amino acid. I recommend that all students learn the structures of the 20 amino acids, their basic properties, and the 3-letter and 1-letter abbreviations.

35 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Is tyrosine hydrophobic? The answer is yes, although as the table shows, it is among the least hydrophobic of the group that is generally defined as hydrophobic.

36 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [3-7] Many tools are available to manipulate sequences. Visit the Sequence Manipulation Suite (http://www.bioinformatics.org/sms2/index.html) to access a large number of tools. (We will encounter a similar suite called EMBOSS in Chapter 8.) What is the reverse complement of the sequence GGAATTCC?

Solutions/comments: The main purpose of this problem is to encourage students to explore this website. Try the Reverse Complement program with the given sequence:

37 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Submit to see the answer: Reverse Complement results >Sample sequence 1 reverse complement GGAATTCC

38 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Solutions to problems: Chapter 4 Basic Local Alignment Search Tool (BLAST)

[4-1] In this problem we will explore the effect of a short protein query on the BLASTP parameters. Perform a BLASTP search at NCBI using the following query of just 12 amino acids: PNLHGLFGRKTG. By default, the parameters are adjusted for short queries. Inspect the output. What is the E value cutoff? What is the word size? What is the scoring matrix? How do these settings compare to the default parameters?

Solutions/comments: Here is the input page:

During the search a message appears:

39 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The “search summary” page shows that the E value was set to 200000. This is a very large value!

The large Expect value serves the function of allowing you to see results in which the result may be biologically meaningful, but the Expect value (related to a probability value) was not very small. E could not be small because, given a short query, there is no opportunity for any alignment to achieve a high score (from E = kmne(exp)-lS a large score is associated with a small E value). The default Expect value is 10. The matrix is PAM30 which is stringent relative to PAM250 or BLOSUM62 (the default matrix): mismataches are not well tolerated. The word size is 2 although the default is 3.

[4-2] Protein searches are usually more informative than DNA searches. Do a BLASTP search using RBP4 (NP_006735), restricting the output to Arthropoda (insects). Next, do a BLASTN search using the RBP4 nucleotide sequence (NM_006744). For this query, select only the nucleotides corresponding to the coding region of the DNA. (To do this visit the NCBI Nucleotide page, follow the link to the coding sequence [CDS], then choose the FASTA format.) Which search is more informative? How many databases matches have an E value less than 1.0 in each search?

Solutions/comments: Here are the settings for the BLASTP search:

40 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) There are about 100 matches having an E value less than 0.01 (while the problem asks about an E value <1, it would have been better to ask about E<0.01). Here are the first matches:

41 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Next find the DNA coding sequence. The BLASTP result has a link to the NCBI protein page; this page (http://www.ncbi.nlm.nih.gov/protein/NP_006735.2) has a link to the DNA (NM_006744.3):

Follow that link and in the features section click the link to CDS (coding sequence):

42 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The CDS is highlighted. At the bottom of the page there is a link to FASTA which produces the sequence starting ATG and ending with a stop codon: >gi|55743121:85-690 Homo sapiens retinol binding protein 4, plasma (RBP4), mRNA ATGAAGTGGGTGTGGGCGCTCTTGCTGTTGGCGGCGCTGGGCAGCGGCCGCGCGGAGCGCGACTGCCGAG TGAGCAGCTTCCGAGTCAAGGAGAACTTCGACAAGGCTCGCTTCTCTGGGACCTGGTACGCCATGGCCAA GAAGGACCCCGAGGGCCTCTTTCTGCAGGACAACATCGTCGCGGAGTTCTCCGTGGACGAGACCGGCCAG ATGAGCGCCACAGCCAAGGGCCGAGTCCGTCTTTTGAATAACTGGGACGTGTGCGCAGACATGGTGGGCA CCTTCACAGACACCGAGGACCCTGCCAAGTTCAAGATGAAGTACTGGGGCGTAGCCTCCTTTCTCCAGAA AGGAAATGATGACCACTGGATCGTCGACACAGACTACGACACGTATGCCGTGCAGTACTCCTGCCGCCTC CTGAACCTCGATGGCACCTGTGCTGACAGCTACTCCTTCGTGTTTTCCCGGGACCCCAACGGCCTGCCCC CAGAAGCGCAGAAGATTGTAAGGCAGCGGCAGGAGGAGCTGTGCCTGGCCAGGCAGTACAGGCTGATCGT CCACAACGGTTACTGCGATGGCAGATCAGAAAGAAACCTTTTGTAG

Use this as a query in a BLASTN search. Note the sequence range is automatically specified to correspond to the CDS:

43 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The result is as follows:

There are just 2 database matches having an Expect value <0.01. The protein search is far more sensitive than the DNA search.

[4-3] This problem introduces batch queries. It is possible to search many queries simultaneously, either using the web-based BLAST (as in this problem) or via locally

44 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) installed BLAST+. Mosses are plants of the phylum Bryophyta, including the non-seed plant Physcomitrella patens that had its genome sequenced (Rensing et al., 2008). Do mosses have any globin proteins, and if so, which human globin(s) are they most closely related to? (1) First obtain the accession numbers of all human globins. There are several approaches to doing this, including BLASTP using beta globin and as queries. Other approaches involve DELTA-BLAST (Chapter 5), or Pfam (Chapter 6). These accession numbers are provided in Web Document 4.7. (2) Perform a BLASTP search using all accession numbers as queries, entering them into the query box. Restrict the output to RefSeq proteins of the mosses. (3) Results for each query are shown (one at a time) via a pull-down menu. Currently there are significant, although distant matches of all human globins to moss proteins except for hemoglobin subunit mu. (See for example the match between human epsilon globin and predicted moss protein XP_001786089.1 with an E value of 0.01. A BLASTP search with that moss protein confirms it is related to many annotated plant globins.) Notably, only one human protein (neuroglobin, NP_001030585.1) has very strong matches to moss proteins such as P. patens predicted protein XP_001764902.1 (E value 2e-10, 27% identity across a span of 138 amino acid residues).

Solutions/comments: I obtained a list of accession numbers of human RefSeq proteins that are globins by using HBB (NP_000509) in a DELTA-BLAST search, selecting “all” of the 15 significant results, clicking “download” and sending the results to a csv file, and parsing them to get this list: NP_000175.1 NP_000509.1 NP_000510.1 NP_000550.2 NP_005321.1 NP_005323.1 XP_005255344.1 NP_000508.1 NP_005322.1 NP_001003938.1 XP_005257062.1 NP_599030.1 NP_067080.1 NP_005359.1 XP_011522574.1 XP_005255345.1 NP_000549.1 NP_976311.1 XP_011520773.1 NP_976312.1 XP_011520774.1 XP_005261662.1 45 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) XP_011518338.1

I then performed a BLASTP search of the RefSeq database, restricting the organism to mosses.

The output includes a pull-down menu allowing you to inspect the results from each protein query. The best results (shown below) are for human neuroglobin as a query; matches to moss proteins have convincing Expect values of 2e-10 and 2e-6.

46 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [4-4] Use the BLAST+ suite to run BLASTP on the command line. Start with default settings, then change the effective database size for your search making it 1000 times smaller then 1000 times larger. What are the E values? Explore different output formats by using the help function; for example, use -outfmt 2 for a multiple alignment format.

Solutions/comments:

47 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) On a Mac terminal, install BLAST+. Enter the command blastp -h to see “help” i.e. the basic usage.

In the BLAST directory I make a new directory (called database) using the mkdir utility. Then I cd (change directory) to enter it. This is where I will download my database of interest.

As described in Chapter 4 we use a Perl script supplied with your blast+ download to automatically download an NCBI database. List available databases. $ indicates the command prompt, ~ refers to the home directory, we refer to the update_blastdb.pl perl utility, the --showall argument displays the available databases, we piple (|) the results to the less utility so we can display them one page at a time.

48 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Next download the RefSeq protein database:

49 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) View the contents of the directory with ls; then unpack one of the files; then again use ls to view the contents of the directory.

50 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Proceed to do a BLASTP search:

Here is part of the result:

51 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here is the first alignment within the result:

To change the database size, use the following command: blastp -query hbb.txt -db ./database/refseq_protein -dbsize 9750000 -out mysearch2 You can enter any value for the database size. If you reduce it by 1000-fold, consider the equation E = kmne(exp)-lamdaS. As the right side of the equation is reduced by a thousand (since effective database size corresponds to mn), the left side will also be reduced by 1000-fold. This example was given within Chapter 4.

52 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [4-5] BLAST+ is useful to do batch queries. Create a text file named 3proteins.txt having three protein sequences: human beta globin, bovine odorant-binding protein, and b from the parasite . (These are available at web document 4.8.) Search them with BLASTP against the RefSeq protein database. The output file includes the results of three separate BLASTP searches.

Solutions/comments: We can use EDirect to acquire the sequences. See http://www.ncbi.nlm.nih.gov/books/NBK179288/ for detailed download and usage instructions. Here we use the esearch utility, search the database (-db) of proteins, set the query to NP_000509 (HBB), pipe the results to efetch which lets us format the output as a FASTA file. We first display the result (which looks correct), and on the next line we repeat the search sending the output (with the > utility) to a file named hbb.txt.

For bovine OBP an accession is XP_002700515; for the accession is NP_059668. Modify the EDirect search to include all 3 proteins in a file.

Here is that file in a text format: lt-pevsnermac-2:3e_problems pevsner$ cat my3proteins.txt >gi|4504349|ref|NP_000509.1| hemoglobin subunit beta [Homo sapiens] MVHLTPEEKSAVTALWGKVNVDEVGGEALGRLLVVYPWTQRFFESFGDLSTPDAVMGNPKVKAHGKKVLG AFSDGLAHLDNLKGTFATLSELHCDKLHVDPENFRLLGNVLVCVLAHHFGKEFTPPVQAAYQKVVAGVAN ALAHKYH >gi|129022|sp|P07435.2|OBP_BOVIN RecName: Full=Odorant-binding protein; Short=OBP; AltName: Full=Olfactory mucosa pyrazine-binding protein AQEEEAEQNLSELSGPWRTVYIGSTNPEKIQENGPFRTYFRELVFDDEKGTVDFYFSVKRDGKWKNVHVK ATKQDDGTYVADYEGQNVFKIVSLSRTHLVAHNINVDKHGQTTELTELFVKLNVEDEDLEKFWKLTEDKG IDKKNVVNFLENEDHPHPE >gi|11466247|ref|NP_059668.1| cytochrome b (mitochondrion) [Plasmodium falciparum] MNFYSINLVKAHLINYPCPLNINFLWNYGFLLGIIFFIQIITGVFLASRYTPDVSYAYYSIQHILRELWS 53 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) GWCFRYMHATGASLVFLLTYLHILRGLNYSYMYLPLSWISGLILFMIFIVTAFVGYVLPWGQMSYWGATV ITNLLSSIPVAVIWICGGYTVSDPTIKRFFVLHFILPFIGLCIVFIHIFFLHLHGSTNPLGYDTALKIPF YPNLLSLDVKGFNNVIILFLIQSLFGIIPLSHPDNAIVVNTYVTPSQIVPEWYFLPFYAMLKTVPSKPAG LVIVLLSLQLLFLLAEQRSLTTIIQFKMIFGARDYSVPIIWFMCAFYALLWIGCQLPQDIFILYGRLFIV LFFCSGLFVLVHYRRTHYDYSSQANI Here is a command to run a BLASTP search using the file with 3 proteins as a query: lt-pevsnermac-2:3e_problems pevsner$ blastp -query my3proteins.txt -db ~/PROGRAMS/blast/database/refseq_protein -out mysearch2_3proteins You can choose any name you like for the output; since we may perform a series of searches I name them sequentially mysearch1, mysearch2, etc. Here is a portion of the output, showing the single file that includes a large set of results for each query: here we see the last globin match, followed by the list of the odorant-binding protein matches.

54 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [4-6] For the search you just performed in problem 4.5, what happens if you use a scoring matrix that is more suited to finding distantly related proteins?

Solutions/comments: Run this command: lt-pevsnermac-2:3e_problems pevsner$ blastp -query my3proteins.txt -db ~/PROGRAMS/blast/database/refseq_protein -matrix -pam30 -out mysearch3_3proteins_pam30 55 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [4-7] Is the pol protein of HIV-1 more closely related to the pol protein of HIV-2 or to the pol protein of simian immunodeficiency virus (SIV)? Use the BLASTP program to decide. Hint: try the Entrez command “NOT hiv-1[organism]” to focus the search away from HIV-1 matches.

Solutions/comments: Enter HIV at NCBI, follow the Genome link, follow the Protein link, and obtain the HIV-1 gag- pol sequence of 1435 amino acids (available at http://www.ncbi.nlm.nih.gov/protein/28872819?report=fasta): >gi|28872819|ref|NP_057849.4| Gag-Pol [Human immunodeficiency virus 1] MGARASVLSGGELDRWEKIRLRPGGKKKYKLKHIVWASRELERFAVNPGLLETSEGCRQILGQLQPSLQT GSEELRSLYNTVATLYCVHQRIEIKDTKEALDKIEEEQNKSKKKAQQAAADTGHSNQVSQNYPIVQNIQG QMVHQAISPRTLNAWVKVVEEKAFSPEVIPMFSALSEGATPQDLNTMLNTVGGHQAAMQMLKETINEEAA EWDRVHPVHAGPIAPGQMREPRGSDIAGTTSTLQEQIGWMTNNPPIPVGEIYKRWIILGLNKIVRMYSPT SILDIRQGPKEPFRDYVDRFYKTLRAEQASQEVKNWMTETLLVQNANPDCKTILKALGPAATLEEMMTAC QGVGGPGHKARVLAEAMSQVTNSATIMMQRGNFRNQRKIVKCFNCGKEGHTARNCRAPRKKGCWKCGKEG HQMKDCTERQANFLREDLAFLQGKAREFSSEQTRANSPTRRELQVWGRDNNSPSEAGADRQGTVSFNFPQ VTLWQRPLVTIKIGGQLKEALLDTGADDTVLEEMSLPGRWKPKMIGGIGGFIKVRQYDQILIEICGHKAI GTVLVGPTPVNIIGRNLLTQIGCTLNFPISPIETVPVKLKPGMDGPKVKQWPLTEEKIKALVEICTEMEK EGKISKIGPENPYNTPVFAIKKKDSTKWRKLVDFRELNKRTQDFWEVQLGIPHPAGLKKKKSVTVLDVGD AYFSVPLDEDFRKYTAFTIPSINNETPGIRYQYNVLPQGWKGSPAIFQSSMTKILEPFRKQNPDIVIYQY MDDLYVGSDLEIGQHRTKIEELRQHLLRWGLTTPDKKHQKEPPFLWMGYELHPDKWTVQPIVLPEKDSWT VNDIQKLVGKLNWASQIYPGIKVRQLCKLLRGTKALTEVIPLTEEAELELAENREILKEPVHGVYYDPSK DLIAEIQKQGQGQWTYQIYQEPFKNLKTGKYARMRGAHTNDVKQLTEAVQKITTESIVIWGKTPKFKLPI QKETWETWWTEYWQATWIPEWEFVNTPPLVKLWYQLEKEPIVGAETFYVDGAANRETKLGKAGYVTNRGR QKVVTLTDTTNQKTELQAIYLALQDSGLEVNIVTDSQYALGIIQAQPDQSESELVNQIIEQLIKKEKVYL AWVPAHKGIGGNEQVDKLVSAGIRKVLFLDGIDKAQDEHEKYHSNWRAMASDFNLPPVVAKEIVASCDKC QLKGEAMHGQVDCSPGIWQLDCTHLEGKVILVAVHVASGYIEAEVIPAETGQETAYFLLKLAGRWPVKTI HTDNGSNFTGATVRAACWWAGIKQEFGIPYNPQSQGVVESMNKELKKIIGQVRDQAEHLKTAVQMAVFIH NFKRKGGIGGYSAGERIVDIIATDIQTKELQKQITKIQNFRVYYRDSRNPLWKGPAKLLWKGEGAVVIQD NSDIKVVPRRKAKIIRDYGKQMAGDDCVASRQDED On the right sidebar click Run BLAST, excluding the organism HIV-1 as shown here (note the Exclude box is checked):

56 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here is the result:

Both proteins are comparably related. The SIV protein has slightly higher coverage (99% versus 98%) and a slightly higher score, but both have E values of 0.

[4-8] “The Iceman” is a man who lived 5300 years ago and whose body was recovered from the Italian Alps in 1991. Some fungal material was recovered from his clothing and sequenced. To what modern species is the fungal DNA most related?

Solutions/comments: Search NCBI Nucleotide with the query iceman. Many hits are found:

57 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Select one or more of these matches. For example, select the first (accession Z54155), select run BLAST (from the right sidebar), search the RefSeq database with the BLASTX program. The best match is to a fungus, Zymoseptoria tritici IPO323 (Mycosphaerella graminicola IPO323). ORGANISM Zymoseptoria tritici IPO323 Eukaryota; Fungi; Dikarya; Ascomycota; Pezizomycotina; Dothideomycetes; Dothideomycetidae; Capnodiales; Mycosphaerellaceae; Zymoseptoria. A search of the nonredundant (nr) collection with BLASTN shows a close match to the fungus Phaeosphaeria as shown here:

58 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [4-9] You perform a BLAST search and a result has an E value of about 1 × 10–4. What does this E value mean? What are some parameters on which an E value depends?

Solutions/comments: Each Expect value has an associated score S. An Expect value of 1e-4 means that for the query you used, and for the database you searched of some particular size, you can expect to obtain a score ≥S by chance one time in 10,000. You can safely reject the null hypothesis which states that the alignmenet between the query and the database match occurred by chance (i.e. the null hypothesis implies that these two sequences are not significantly related). Such an E value implies homology, i.e. that these sequences (or at least the portion of these sequences that aligns and is reported in your BLAST result) are descended from a common ancestor.

59 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Solutions to problems: Chapter 5 Advanced Database Searching

[5-1] Create an artificial protein sequence consisting of human RBP4 followed by the C2 domain of human protein kinase Cα. An example of this is shown in Web Document 5.5. Enter this combined sequence into a PSI-BLAST search. In general, are multiple domains always detected by the PSI-BLAST program? Do any naturally occurring proteins have both lipocalin and C2 domains?

Solutions/comments: Here is RBP4, obtained via NCBI Gene then RefSeq: >gi|55743122|ref|NP_006735.2| retinol-binding protein 4 precursor [Homo sapiens] MKWVWALLLLAALGSGRAERDCRVSSFRVKENFDKARFSGTWYAMAKKDPEGLFLQDNIVAEFSVDETGQ MSATAKGRVRLLNNWDVCADMVGTFTDTEDPAKFKMKYWGVASFLQKGNDDHWIVDTDYDTYAVQYSCRL LNLDGTCADSYSFVFSRDPNGLPPEAQKIVRQRQEELCLARQYRLIVHNGYCDGRSERNLL Here is the entire PKCA protein: C2 domain

>gi|4506067|ref|NP_002728.1| protein kinase C alpha type [Homo sapiens] MADVFPGNDSTASQDVANRFARKGALRQKNVHEVKDHKFIARFFKQPTFCSHCTDFIWGFGKQGFQCQVC CFVVHKRCHEFVTFSCPGADKGPDTDDPRSKHKFKIHTYGSPTFCDHCGSLLYGLIHQGMKCDTCDMNVH KQCVINVPSLCGMDHTEKRGRIYLKAEVADEKLHVTVRDAKNLIPMDPNGLSDPYVKLKLIPDPKNESKQ KTKTIRSTLNPQWNESFTFKLKPSDKDRRLSVEIWDWDRTTRNDFMGSLSFGVSELMKMPASGWYKLLNQ EEGEYYNVPIPEGDEEGNMELRQKFEKAKLGPAGNKVISPSEDRKQPSNNLDRVKLTDFNFLMVLGKGSF GKVMLADRKGTEELYAIKILKKDVVIQDDDVECTMVEKRVLALLDKPPFLTQLHSCFQTVDRLYFVMEYV NGGDLMYHIQQVGKFKEPQAVFYAAEISIGLFFLHKRGIIYRDLKLDNVMLDSEGHIKIADFGMCKEHMM DGVTTRTFCGTPDYIAPEIIAYQPYGKSVDWWAYGVLLYEMLAGQPPFDGEDEDELFQSIMEHNVSYPKS LSKEAVSICKGLMTKHPAKRLGCGPEGERDVREHAFFRRIDWEKLENREIQPPFKPKVCGKGAENFDKFF TRGQPVLTPPDQLVIANIDQSDFEGFSYVNPQFVHPILQSAV Here is the C2 domain of PKCA, obtained by clicking the C2 “region” link from the NCBI Protein page (http://www.ncbi.nlm.nih.gov/protein/NP_002728.1): >gi|4506067:159-289 protein kinase C alpha type [Homo sapiens] RGRIYLKAEVADEKLHVTVRDAKNLIPMDPNGLSDPYVKLKLIPDPKNESKQKTKTIRSTLNPQWNESFT FKLKPSDKDRRLSVEIWDWDRTTRNDFMGSLSFGVSELMKMPASGWYKLLNQEEGEYYNVP Here is a chimeric protein: MKWVWALLLLAALGSGRAERDCRVSSFRVKENFDKARFSGTWYAMAKKDPEGLFLQDNIVAEFSVDETGQ MSATAKGRVRLLNNWDVCADMVGTFTDTEDPAKFKMKYWGVASFLQKGNDDHWIVDTDYDTYAVQYSCRL LNLDGTCADSYSFVFSRDPNGLPPEAQKIVRQRQEELCLARQYRLIVHNGYCDGRSERNLLRGRIYLKAE VADEKLHVTVRDAKNLIPMDPNGLSDPYVKLKLIPDPKNESKQKTKTIRSTLNPQWNESFTFKLKPSDKD RRLSVEIWDWDRTTRNDFMGSLSFGVSELMKMPASGWYKLLNQEEGEYYNVP Use this as a query in a PSI-BLAST search (against RefSeq); you find PSI-BLAST as one of the BLASTP family of programs. The graphical portion of the result suggests that there are matches to either RBP4 or to PKC but not both; the RBP4 portion of the protein is larger so it accumulates higher scores (and lower E values) and those results are listed first. By inspection there are no proteins with both domains. Later we will explore the Pfam database that explicitly summarizes domain architectures.

60 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [5-2] The purpose of this problem is to compare BLASTP to DELTA-BLAST. The malarium parasite Plasmodium vivax has a multigene family called vir that is specific to that organism (del Portillo et al., 2001). There are 600–1000 copies of these genes, and they may have a role in causing chronic infection through antigenic variation. Select vir1 and perform a BLASTP search of the nonredundant protein database (restricting the species to Plasmodium vivax). Then perform a DELTA-BLAST search with the same entry. For each search, approximately how many proteins have an E value less than 1e-10?

61 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Solutions/comments: Find vir-1 protein from Plasmodium vivax search NCBI Protein: "Plasmodium vivax"[ORGN] vir1 (see http://www.ncbi.nlm.nih.gov/protein/CAB96690.1). Run BLASTP:

Here is the result: there are many matches with significant E values.

62 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) 63 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Next “Edit and resubmit” and change from BLASTP to DELTA-BLAST.

64 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here is the result:

65 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) 66 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) In a way the results of this particular search are in some sense surprising.  BLASTP successfully found a series of matches, including a top four (color-coded red) with very low E values from 0 to 1e-88.  DELTA-BLAST successfully found many more matches (using its PSSM-based approach). However its best match (8e-53) does not have as low an Expect value as produced by BLASTP. In many other DELTA-BLAST searches the E values are better (lower) than those found by BLASTP. The result shown here follows from the PSSM approach used by DELTA-BLAST in which a large set of vir1-related proteins were aligned and scored to define the general properties of this family.

[5-3] Are there globins in fungi? Perform a PSI-BLAST search using human beta globin (NP_000509) as a query, restricting the output to sequences from fungi (taxid:4751) in the nr database. What is the approximate range of lengths of fungal proteins having globin domains? What non-globin domains are often present in fungal globins? Does the presence of these unrelated domains lead to corruption? Why or why not? In the first iteration there are several hits (with the E values below the 0.005 threshold). After several more iterations there are many dozens of hits including flavohemoproteins that include a globin domain. These fungal proteins have globin domains that are more related to bacterial than vertebrate orthologs. Most of the fungal flavohemoproteins and are quite long (over 400 amino acids and sometimes about 1000 amino acids long), having multiple domains. However, only the globin domain is used for the continued PSI-BLAST iterations.

Solutions/comments: 67 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here let’s try DELTA-BLAST (rather than PSI-BLAST):

The result that there are indeed many globins in fungi:

68 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) To see the lengths of these matches inspect the pairwise outputs. You can also reformat to view (or export) the resuts as a table. Most fungal proteins have lengths of 250 to 450 amino acids. Some are larger, e.g.:

In many cases these larger fungal globins contain repeating globin units.

[5-4] Perform HMMER searches. First make two different HMMs. You can obtain sets of vertebrate globin and bacterial/fungal/vertebrate globin sequences as web documents 5.6 and 5.7

69 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) at ►http://www.bioinfbook.org/chapter5. The multiple sequence alignments that we use as input to HMMER are in these documents. When the profile HMM was built from a multiple sequence alignment of vertebrate alpha and beta globins and used to search the human RefSeq database, there were many database matches, including that we could not detect with BLASTP. In contrast, when an alignment of bacterial and fungal globins was used to generate a profile HMM, the output consisted of one result with a non-signficant expect value. Combining several human globins with the bacterial and fungal globins in a multiple sequence alignment resulted in the creation of an HMM that readily detected human globins. Thus the profile HMM is a model that is sensitive to the choice of sequences that are used as input for the multiple sequence alignment. The full results of the HMMER searches for (1) vertebrate, (2) bacterial plus fungal, and (3) bacterial plus fungal plus vertebrate globins are shown in web documents 5.8, 5.9, and 5.10 at ►http://www.bioinfbook.org/chapter5. The HMM match to human myoglobin had a higher score and lower E value in search (3) than in (1). HMMer searches are run locally. This search was run against all human RefSeq proteins. You can download NCBI databases such as RefSeq by visiting the file transfer protocol (FTP) site from the home page of NCBI or going directly to ►http://www.ncbi.nlm.nih.gov/Ftp/ (WebLink 5.1). Place the downloaded database into the same directory as your input sequences for HMMER.

Solutions/comments: Download hmmer software:

On a Mac, go to the download directory and double-click to unpackage. Follow the INSTALL directions. Create a new directory (mkdir hmmer), cd hmmer (go there), move the hmmer package there (mv ~/Downloads/hmm* .). ./configure make

70 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) make test

[5-5] We previously performed a series of BLAST searches using HIV-1 pol as a query (NP_057849). Perform a BLASTP search using this query. Look at the taxonomy report to see which viruses match this query. Next, repeat the search using several iterations of PSI-BLAST. Compare this taxonomy report to that of the BLASTP search. What do you observe? Are there any nonviral sequences detected in the PSI-BLAST search? Did you expect to find any?

Solutions/comments: Note the taxonomy report is linked from the top portion of NCBI BLAST output:

This output shows the lineages and (not shown) E values for different taxonomic groups:

Although the problem mentions PSI-BLAST we will do a single round of DELTA-BLAST. Here is the upper portion of the taxonomy report: 71 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) There are more hits with DELTA-BLAST, both viral and non-viral. This is expected because the PSSM-based approach is far more sensitive than that of standard BLAST.

[5-6] Explore PHI-BLAST using human RBP4 (NP_006735) as a query, restricting the output to bacteria and the RefSeq database. Use the PHI pattern GXW[YF]X[VILMAFY]A[RKH]. Perform this search, and save the results. Then repeat the search using the PHI pattern GXW[YF] [EA][IVLM]. How do the results differ? Select one protein that appears as a bacterial protein in a pairwise alignment with the human RBP4 query; what are the E values, and why do they differ?

Solutions/comments: Here is the set-up of the PHI-BLAST search:

72 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) For every database match, the results include asterisks indicating where this pattern matches.The top two patterns are shown here:

73 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Repeat the search with the second pattern which is shorter and more restrictive. The top two results are identical, except that there are 6 asterisks now instead of 8 asterisks previously:

74 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Inspecting the results from both searches, the first one (with the longer PHI pattern) had more database matches that were significant (above threshold). If we instead do a PHI-BLAST search without using a PHI pattern, only one match is significant (the P. luteoviolacea seen above):

75 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Many were previously significant, such as L. daeponensis (see above also), but not significant in the absence of the PHI pattern:

Therefore a PHI pattern can dramatically improve the sensitivity of a BLAST protein search.

76 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Solutions to problems: Chapter 6 Multiple Sequence Alignment

[6-1] Practice using three NCBI resources to obtain groups of sequences in the FASTA format that you can use for multiple sequence alignment. Select a keyword such as cytochrome (other suggestions are ferritin, S100 or trypsin). In a first approach, enter this search from the home page of NCBI, and follow the link to HomoloGene. By default, the entries are displayed in the summary format. Using the pull-down menu change the display to Multiple Alignment. This allows you to scroll through a series of multiple sequence alignments. Select one for further study. It is helpful to choose one in which there are some gaps, so that you can evaluate the performance of various software programs (in problem [10-2]). Once you identify a group of proteins of interest, click to view that HomoloGene group, and change the display to FASTA. Copy these sequences and/or save them to a text document. In a second approach, repeat this exercise beginning at the home page of NCBI, but select the link to CDD (the conserved domain database). Here, there are pfam, cdd, smart, and/or COG identifiers. Select an entry with a CDD identifier (such as cd00904 for ferritin). Here, a multiple sequence alignment is shown. Change the format to obtain the desired number of proteins in this family (e.g. up to 5, 10, or 20) in the FASTA format; you may select the most diverse members of this group. In a third approach, perform a BLASTP search using a query such as ferritin light chain (NP_000137) and inspect the pairwise alignments to the query. Select a group of ten proteins by clicking on the box next to each, and click “Get selected sequences.” These ten protein appear on an NCBI Protein page; change the display option to FASTA and use the pull-down menu option “send to text.” The sequences are now available in the FASTA format for further study.

Solutions/comments: We begin at the home page of NCBI with a search for S100:

The Entrez results include 83 HomoloGene entries:

The HomoloGene results include S100 as the third entry: 77 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here is a portion of the HomoloGene entry. This one happens to have just three proteins. Note the “Download” link at upper right.

The Download page allows you to download protein or DNA sequences for subsequent analyses.

78 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The following image shows the HomoloGene entry as a multiple sequence alignment.

We can also visit the Conserved Domain Database (CDD) (at http://www.ncbi.nlm.nih.gov/cdd/), also accessed by searching the home page of NCBI.

79 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The results include S-100A11:

That entry includes structure information and also a multiple sequence alignment that you can reformat as a text file or multiple FASTA file to save and study further.

Here is a third approach to obtaining sequences. Perform BLASTP using ferritin (NP_000137) as a query, restricting the output to the RefSeq database. Here are the results:

80 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Select several of the hits (by checking the boxes) and a download menu appears:

Note there are several download options.

Upon downloading you obtain a text file containing sequences, here in the FASTA format.

81 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here are five ferritin proteins: >gi|20149498|ref|NP_000137.2| ferritin light chain [Homo sapiens] MSSQIRQNYSTDVEAAVNSLVNLYLQASYTYLSLGFYFDRDDVALEGVSHFFRELAEEKREGYERLLKMQNQRGGRALFQ DIKKPAEDEWGKTPDAMKAAMALEKKLNQALLDLHALGSARTDPHLCDFLETHFLDEEVKLIKKMGDHLTNLHRLGGPEA GLGEYLFERLTLKHD >gi|675727332|ref|XP_008965255.1| PREDICTED: ferritin light chain [Pan paniscus] MTQQSLPATRTPDTGLAGHLQIPSNQPQGPNPPKPPFHNTLALQARDFPLLWGGGLRLLCAPDWSGTAFGPASCRRRLAA SPPRAPCLRGPAHYKRSRPSHVPSQFGGPAGLSLASTVFGRNRSGDSLPASDCPPISSPLATSGTIFSAISCFWDLPAPF LWLAPSCQPTMSSQIRQNYSTDVEAAVNSLVNLYLQASYTYLSLGFYFDRDDVALEGVSHFFRELAEEKREGYERLLKMQ NQRGGRALFQDIKKPAEDEWGKTPDAMKAAMALEKKLNQALLDLHALGSAHTDPHLCDFLETHFLDEEVKLIKKMGDHLT NLHRLGGPEAGLGEYLFERLTLKHD >gi|114326466|ref|NP_034370.2| ferritin light chain 1 [Mus musculus] MTSQIRQNYSTEVEAAVNRLVNLHLRASYTYLSLGFFFDRDDVALEGVGHFFRELAEEKREGAERLLEFQNDRGGRALFQ DVQKPSQDEWGKTQEAMEAALAMEKNLNQALLDLHALGSARADPHLCDFLESHYLDKEVKLIKKMGNHLTNLRRVAGPQP AQTGAPQGSLGEYLFERLTLKHD >gi|545194593|ref|XP_005602735.1| PREDICTED: ferritin light chain [Equus caballus] MSSHIRQNYSTEVEAAINRLVNLYLRASYTYLSLGFYFNRDDVALEGVCHFFCELAEEKRECAKCLLKMQNQHGDHALFQ DLQKPSQDEWGTTLDAMKAAVVLEKSLNQALLDLHALGSAHADPHLCDFLESHFLDEEVKLIKKMGDNLTNIQRLVGPQA GLGECLFERLTLKHD >gi|545500999|ref|XP_005621156.1| PREDICTED: ferritin light chain-like [Canis lupus familiaris] MSSRIRQNYSTEVEAVVNRLVNMHLRASYTYLSLGFYFDRDDVALEGVGHFFRELEKCEGAERFLKMQNQRGGCALFQDV QKPSQDEWGKTLDAMEAALLLEKNLNQALLDLHALGSARADPHLCDFLENHFLDEVKLIKKMGDHLTNLRRLATPQAGLG EYLFERLTLKHD It can be helpful to simplify the header lines, as follows; these are ferritin light chains from five species. >human NP_000137.2 MSSQIRQNYSTDVEAAVNSLVNLYLQASYTYLSLGFYFDRDDVALEGVSHFFRELAEEKREGYERLLKMQNQRGGRALFQ DIKKPAEDEWGKTPDAMKAAMALEKKLNQALLDLHALGSARTDPHLCDFLETHFLDEEVKLIKKMGDHLTNLHRLGGPEA GLGEYLFERLTLKHD >bonobo XP_008965255.1 MTQQSLPATRTPDTGLAGHLQIPSNQPQGPNPPKPPFHNTLALQARDFPLLWGGGLRLLCAPDWSGTAFGPASCRRRLAA SPPRAPCLRGPAHYKRSRPSHVPSQFGGPAGLSLASTVFGRNRSGDSLPASDCPPISSPLATSGTIFSAISCFWDLPAPF LWLAPSCQPTMSSQIRQNYSTDVEAAVNSLVNLYLQASYTYLSLGFYFDRDDVALEGVSHFFRELAEEKREGYERLLKMQ NQRGGRALFQDIKKPAEDEWGKTPDAMKAAMALEKKLNQALLDLHALGSAHTDPHLCDFLETHFLDEEVKLIKKMGDHLT 82 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) NLHRLGGPEAGLGEYLFERLTLKHD >mouse NP_034370.2 MTSQIRQNYSTEVEAAVNRLVNLHLRASYTYLSLGFFFDRDDVALEGVGHFFRELAEEKREGAERLLEFQNDRGGRALFQ DVQKPSQDEWGKTQEAMEAALAMEKNLNQALLDLHALGSARADPHLCDFLESHYLDKEVKLIKKMGNHLTNLRRVAGPQP AQTGAPQGSLGEYLFERLTLKHD >horse XP_005602735.1 MSSHIRQNYSTEVEAAINRLVNLYLRASYTYLSLGFYFNRDDVALEGVCHFFCELAEEKRECAKCLLKMQNQHGDHALFQ DLQKPSQDEWGTTLDAMKAAVVLEKSLNQALLDLHALGSAHADPHLCDFLESHFLDEEVKLIKKMGDNLTNIQRLVGPQA GLGECLFERLTLKHD >dog XP_005621156.1 MSSRIRQNYSTEVEAVVNRLVNMHLRASYTYLSLGFYFDRDDVALEGVGHFFRELEKCEGAERFLKMQNQRGGCALFQDV QKPSQDEWGKTLDAMEAALLLEKNLNQALLDLHALGSARADPHLCDFLENHFLDEVKLIKKMGDHLTNLRRLATPQAGLG EYLFERLTLKHD

[6-2] Using the FASTA-formatted sequences from problem [6-1], perform multiple sequence alignments using programs available at the European Bioinformatics Institute: MAFFT, Muscle, and T-Coffee. Save and compare each result. How do they differ? How can you assess which is likely to be the most accurate? When applicable, try adjusting the parameters such as the scoring matrices, gap opening and extension penalties, or number of iterations to see the effects on the alignments.

Solutions/comments: If you choose a set of sequences from a HomoloGene entry it is possible (even likely) that they will all be so closely related that all multiple alignment programs give equal (or closely similar) results. It is more interesting to find sequences that are less related. One approach is to use the Conserved Domain Database (as shown in the previous problem, bottom image) and select the most diverse members of a set. Select trypsin:

View the 10 most diverse members of the family (note the main insertion/deletion sites):

83 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) As another approach, take the five ferritin light chain proteins from problem [6-1] and enter them into the MAFFT site at EBI (http://www.ebi.ac.uk/Tools/msa/mafft/), setting the output format to ClustalW. The result shows that the bonobo protein, which has the XP_ RefSeq accession typical of some predicted proteins; while this is an open reading frame, it is reasonable to assume that the correct amino-terminal methionine is aligned with all the other amino-termini. The dog protein has a short deletion, and the mouse protein has an insertion.

84 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) For this particular set of proteins the EBI MUSCLE output is essentially the same (the order of the proteins is different):

85 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) To see differences between MSA programs it is helpful to choose more divergent sequences. Try adding these: >gi|91081285|ref|XP_967895.1| PREDICTED: soma ferritin [Tribolium castaneum] MAQSQVRQNFHKDCEDAINKQINVELNAFYTYLSMAYHFQRDDVALPGLYKYFKACSDEERDHAHKLMEYLNKRGGRLAL TDIPAPEKQDWGTAQEAMCAALDLEKRVNESLLVLHSTASGHMDVNLCDFLETHYLQEQVDAIKEIADHVTNLKRVGEGL GVYMFDRTLADE >gi|24641673|ref|NP_572854.1| ferritin 3 heavy chain homologue [Drosophila melanogaster] MAWCFRDIRRHMCMLVRQNFAKSCEKKLNDQINMELKASHQYLAMAYHFDRSDISSPGMHRFFLKASVEEREHAEKIMTY MNKRGGLIILSSVPQPLPCFASTLDALKHAMKMELEVNKHLLDLHALAGKEADPNLCDFIEANFLQEQVDGQKILADYIS QLEKAQNQVGEFLFDKYMGSGMHPAK >gi|453232411|ref|NP_504944.2| FTN-1 [Caenorhabditis elegans] 86 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) MSLARQNYHDEVEAAVNKQINVELYASYVYLSMSAHFDRDDIALRNIAKFFKEQSDEERGHATELMRIQAVRGGRVAMQN IQKPEKDEWGTVLEAFEAALALERANNASLLKLHGIAEQRNDAHLTNYIQEKYLEEQVHSINEFARYIANIKRAGPGLGE YLFDKEEFSD >gi|524888390|ref|XP_005100766.1| PREDICTED: ferritin light chain, oocyte isoform-like isoform X1 [Aplysia californica] MTNRGFVLFCVLKMSLHTGVLLILMVTISSIQPTDYSRDANVEISSRCQKRVKRCGQFKPPKPEMGEMSCSFSARTCGFA CDLICPTPEGKTALVLNQKRHGRDMYLCTAGNWKRRETPQTFCKAQWPVKEVRQNLHHVENLNGLVNKLLNTSYFYLGMA SFYERADVALPGFSKLMTDLWSADQSHARDLMSYVNKRGGYITLYDIPRTPSHEVLLLKLSSRIGQAGVEMALQAAREVN EQVLELHKNATLPGDSNDPHLKHALEDGLLSSKVELIKKLADVDRRLHAFPEEDYAVGEYVLDQEQLG Rename them: >beetle XP_967895.1 MAQSQVRQNFHKDCEDAINKQINVELNAFYTYLSMAYHFQRDDVALPGLYKYFKACSDEERDHAHKLMEYLNKRGGRLAL TDIPAPEKQDWGTAQEAMCAALDLEKRVNESLLVLHSTASGHMDVNLCDFLETHYLQEQVDAIKEIADHVTNLKRVGEGL GVYMFDRTLADE >fly NP_572854.1 MAWCFRDIRRHMCMLVRQNFAKSCEKKLNDQINMELKASHQYLAMAYHFDRSDISSPGMHRFFLKASVEEREHAEKIMTY MNKRGGLIILSSVPQPLPCFASTLDALKHAMKMELEVNKHLLDLHALAGKEADPNLCDFIEANFLQEQVDGQKILADYIS QLEKAQNQVGEFLFDKYMGSGMHPAK >nematode NP_504944.2 MSLARQNYHDEVEAAVNKQINVELYASYVYLSMSAHFDRDDIALRNIAKFFKEQSDEERGHATELMRIQAVRGGRVAMQN IQKPEKDEWGTVLEAFEAALALERANNASLLKLHGIAEQRNDAHLTNYIQEKYLEEQVHSINEFARYIANIKRAGPGLGE YLFDKEEFSD >Aplysia XP_005100766.1 MTNRGFVLFCVLKMSLHTGVLLILMVTISSIQPTDYSRDANVEISSRCQKRVKRCGQFKPPKPEMGEMSCSFSARTCGFA CDLICPTPEGKTALVLNQKRHGRDMYLCTAGNWKRRETPQTFCKAQWPVKEVRQNLHHVENLNGLVNKLLNTSYFYLGMA SFYERADVALPGFSKLMTDLWSADQSHARDLMSYVNKRGGYITLYDIPRTPSHEVLLLKLSSRIGQAGVEMALQAAREVN EQVLELHKNATLPGDSNDPHLKHALEDGLLSSKVELIKKLADVDRRLHAFPEEDYAVGEYVLDQEQLG Add them, creating a set of 9 ferritins: >human NP_000137.2 MSSQIRQNYSTDVEAAVNSLVNLYLQASYTYLSLGFYFDRDDVALEGVSHFFRELAEEKREGYERLLKMQNQRGGRALFQ DIKKPAEDEWGKTPDAMKAAMALEKKLNQALLDLHALGSARTDPHLCDFLETHFLDEEVKLIKKMGDHLTNLHRLGGPEA GLGEYLFERLTLKHD >bonobo XP_008965255.1 MTQQSLPATRTPDTGLAGHLQIPSNQPQGPNPPKPPFHNTLALQARDFPLLWGGGLRLLCAPDWSGTAFGPASCRRRLAA SPPRAPCLRGPAHYKRSRPSHVPSQFGGPAGLSLASTVFGRNRSGDSLPASDCPPISSPLATSGTIFSAISCFWDLPAPF LWLAPSCQPTMSSQIRQNYSTDVEAAVNSLVNLYLQASYTYLSLGFYFDRDDVALEGVSHFFRELAEEKREGYERLLKMQ NQRGGRALFQDIKKPAEDEWGKTPDAMKAAMALEKKLNQALLDLHALGSAHTDPHLCDFLETHFLDEEVKLIKKMGDHLT NLHRLGGPEAGLGEYLFERLTLKHD >mouse NP_034370.2 MTSQIRQNYSTEVEAAVNRLVNLHLRASYTYLSLGFFFDRDDVALEGVGHFFRELAEEKREGAERLLEFQNDRGGRALFQ DVQKPSQDEWGKTQEAMEAALAMEKNLNQALLDLHALGSARADPHLCDFLESHYLDKEVKLIKKMGNHLTNLRRVAGPQP AQTGAPQGSLGEYLFERLTLKHD >horse XP_005602735.1 MSSHIRQNYSTEVEAAINRLVNLYLRASYTYLSLGFYFNRDDVALEGVCHFFCELAEEKRECAKCLLKMQNQHGDHALFQ DLQKPSQDEWGTTLDAMKAAVVLEKSLNQALLDLHALGSAHADPHLCDFLESHFLDEEVKLIKKMGDNLTNIQRLVGPQA GLGECLFERLTLKHD >dog XP_005621156.1 MSSRIRQNYSTEVEAVVNRLVNMHLRASYTYLSLGFYFDRDDVALEGVGHFFRELEKCEGAERFLKMQNQRGGCALFQDV QKPSQDEWGKTLDAMEAALLLEKNLNQALLDLHALGSARADPHLCDFLENHFLDEVKLIKKMGDHLTNLRRLATPQAGLG EYLFERLTLKHD >beetle XP_967895.1 MAQSQVRQNFHKDCEDAINKQINVELNAFYTYLSMAYHFQRDDVALPGLYKYFKACSDEERDHAHKLMEYLNKRGGRLAL TDIPAPEKQDWGTAQEAMCAALDLEKRVNESLLVLHSTASGHMDVNLCDFLETHYLQEQVDAIKEIADHVTNLKRVGEGL GVYMFDRTLADE >fly NP_572854.1 MAWCFRDIRRHMCMLVRQNFAKSCEKKLNDQINMELKASHQYLAMAYHFDRSDISSPGMHRFFLKASVEEREHAEKIMTY MNKRGGLIILSSVPQPLPCFASTLDALKHAMKMELEVNKHLLDLHALAGKEADPNLCDFIEANFLQEQVDGQKILADYIS QLEKAQNQVGEFLFDKYMGSGMHPAK >nematode NP_504944.2 MSLARQNYHDEVEAAVNKQINVELYASYVYLSMSAHFDRDDIALRNIAKFFKEQSDEERGHATELMRIQAVRGGRVAMQN IQKPEKDEWGTVLEAFEAALALERANNASLLKLHGIAEQRNDAHLTNYIQEKYLEEQVHSINEFARYIANIKRAGPGLGE YLFDKEEFSD 87 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) >Aplysia XP_005100766.1 MTNRGFVLFCVLKMSLHTGVLLILMVTISSIQPTDYSRDANVEISSRCQKRVKRCGQFKPPKPEMGEMSCSFSARTCGFA CDLICPTPEGKTALVLNQKRHGRDMYLCTAGNWKRRETPQTFCKAQWPVKEVRQNLHHVENLNGLVNKLLNTSYFYLGMA SFYERADVALPGFSKLMTDLWSADQSHARDLMSYVNKRGGYITLYDIPRTPSHEVLLLKLSSRIGQAGVEMALQAAREVN EQVLELHKNATLPGDSNDPHLKHALEDGLLSSKVELIKKLADVDRRLHAFPEEDYAVGEYVLDQEQLG View the EBI MAFFT alignment: CLUSTAL format alignment by MAFFT FFT-NS-i (v7.215) human ------bonobo MTQQS------LPATRTPDTGLAGHLQIPSNQPQGPNPPKPPFHNTLALQARDFPLLWGG mouse ------dog ------horse ------beetle M------nematode M------fly MA------Aplysia MTNRGFVLFCVLKMSLHTGVLLILMVTISSIQPT------

human ------bonobo GLRLLCAPDWSGTAFGPAS--CRRRLAASPPRAPCLRGPAHYKRSRPSHVPSQFGGPAGL mouse ------dog ------horse ------beetle ------nematode ------fly ------W------Aplysia ------DYSRDANVEISSRCQKRVKRC------GQFKPPKPEM------GEMSC

human ------bonobo SLASTVFGRNRSGDSLPASD--CPPISSPLATSGTIFSAISCFWDL------P mouse ------dog ------horse ------beetle ------nematode ------fly ------CFRDI------RRH-- Aplysia SFSARTCGF------ACDLICP---TPEGKTALVLNQKRHGRDMYLCTAGNWKRRETP

human ------MSSQIRQNYSTDVEAAVNSLVNLYLQASYTYLSLGFYFDRDDVALE bonobo APFLWLAPSCQPT-MSSQIRQNYSTDVEAAVNSLVNLYLQASYTYLSLGFYFDRDDVALE mouse ------MTSQIRQNYSTEVEAAVNRLVNLHLRASYTYLSLGFFFDRDDVALE dog ------MSSRIRQNYSTEVEAVVNRLVNMHLRASYTYLSLGFYFDRDDVALE horse ------MSSHIRQNYSTEVEAAINRLVNLYLRASYTYLSLGFYFNRDDVALE beetle ------AQSQVRQNFHKDCEDAINKQINVELNAFYTYLSMAYHFQRDDVALP nematode ------SLARQNYHDEVEAAVNKQINVELYASYVYLSMSAHFDRDDIALR fly ------MCMLVRQNFAKSCEKKLNDQINMELKASHQYLAMAYHFDRSDISSP Aplysia QTF------CKAQWPVKEVRQNLH-HVEN-LNGLVNKLLNTSYFYLGMASFYERADVALP *** * :* :* * : : **.:. .::* *:: human GVSHFFRELAEEKREGYERLLKMQNQRGGRALFQDIKK-PAEDEWGKTPDA------MKA bonobo GVSHFFRELAEEKREGYERLLKMQNQRGGRALFQDIKK-PAEDEWGKTPDA------MKA mouse GVGHFFRELAEEKREGAERLLEFQNDRGGRALFQDVQK-PSQDEWGKTQEA------MEA 88 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) dog GVGHFFREL--EKCEGAERFLKMQNQRGGCALFQDVQK-PSQDEWGKTLDA------MEA horse GVCHFFCELAEEKRECAKCLLKMQNQHGDHALFQDLQK-PSQDEWGTTLDA------MKA beetle GLYKYFKACSDEERDHAHKLMEYLNKRGGRLALTDIPA-PEKQDWGTAQEA------MCA nematode NIAKFFKEQSDEERGHATELMRIQAVRGGRVAMQNIQK-PEKDEWGTVLEA------FEA fly GMHRFFLKASVEEREHAEKIMTYMNKRGGLIILSSVPQ-P-LPCFASTLDA------LKH Aplysia GFSKLMTDLWSADQSHARDLMSYVNKRGGYITLYDIPRTPSHEVLLLKLSSRIGQAGVEM .. : : . :: :*. : .: * .: . human AMALEKKLNQALLDLH---ALGSARTDPHLCDFLETHFLDEEVKLIKKMGDHLTNLHRLG bonobo AMALEKKLNQALLDLH---ALGSAHTDPHLCDFLETHFLDEEVKLIKKMGDHLTNLHRLG mouse ALAMEKNLNQALLDLH---ALGSARADPHLCDFLESHYLDKEVKLIKKMGNHLTNLRRVA dog ALLLEKNLNQALLDLH---ALGSARADPHLCDFLENHFLD-EVKLIKKMGDHLTNLRRLA horse AVVLEKSLNQALLDLH---ALGSAHADPHLCDFLESHFLDEEVKLIKKMGDNLTNIQRLV beetle ALDLEKRVNESLLVLH---STASGHMDVNLCDFLETHYLQEQVDAIKEIADHVTNLKRVG nematode ALALERANNASLLKLH---GIAEQRNDAHLTNYIQEKYLEEQVHSINEFARYIANIKRAG fly AMKMELEVNKHLLDLH---ALAGKEADPNLCDFIEANFLQEQVDGQKILADYISQLEKAQ Aplysia ALQAAREVNEQVLELHKNATLPGDSNDPHLKHALEDGLLSSKVELIKKLADVDRRLHAFP *: * :* ** * :* . :: *. :*. : :. .:. human G------PEAGLGEYLFERLTLKH----D bonobo G------PEAGLGEYLFERLTLKH----D mouse GPQPAQTGAPQGSLGEYLFERLTLKH----D dog T------PQAGLGEYLFERLTLKH----D horse G------PQAGLGECLFERLTLKH----D beetle ------EGLGVYMFDRTLADE----- nematode ------PGLGEYLFDKEEFSD----- fly ------NQVGEFLFDKYMGSGMHPAK Aplysia E------EDYAVGEYVLDQEQLG------:* :::: Then compare other programs.

[6-3] Use EDirect to access sets of homologous proteins from HomoloGene. These can be viewed in various formats. Retrieve the sets of protein sequences, in the FASTA format, containing the protein HBB. How many HomoloGene entries are there in this set? $ esearch -db homologene -query "HBB" | efetch -db homologene - format fasta 1: HomoloGene:128037. Gene conserved in Boreoeutheria

>gi|4504351|ref|NP_000510.1| hemoglobin subunit delta MVHLTPEEKTAVNALWGKVNVDAVGGEALGRLLVVYPWTQRFFESFGDLSSPDAVMGNPKVKAHGKKVLG AFSDGLAHLDNLKGTFSQLSELHCDKLHVDPENFRLLGNVLVCVLARNFGKEFTPQMQAAYQKVVAGVAN ALAHKYH >gi|332835679|ref|XP_001162045.2| PREDICTED: hemoglobin subunit delta isoform 1 [Pan troglodytes] MVHLTPEEKTAVNALWGKVNVDAVGGEALGRLLVVYPWTQRFFESFGDLSSPDAVMGNPKVKAHGKKVLG AFSDGLAHLDNLKGTFSQLSELHCDKLHVDPENFRLLGNVLVCVLARNFGKEFTPQVQAAYQKVVAGVAN ALAHKYH … Next retrieve the alignment scores (rather than the sequences) for HomoloGene entries containing the protein HBB.

89 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) $ esearch -db homologene -query "HBB" | efetch -db homologene -format alignmentscores 1: HomoloGene:128037. Gene conserved in Boreoeutheria

Pairwise Alignment Scores Gene Identity (%)

Species Symbol Protein DNA

H.sapiens HBD vs. P.troglodytes HBD 99.3 99.3 Blast vs. B.taurus HBB 83.3 86.1 Blast vs. B.taurus HBG 77.8 82.6 Blast vs. B.taurus LOC788610 77.8 82.6 Blast P.troglodytes HBD vs. H.sapiens HBD 99.3 99.3 Blast vs. B.taurus HBB 83.3 85.9 Blast vs. B.taurus HBG 77.8 82.4 Blast vs. B.taurus LOC788610 77.8 82.4 Blast …

Solutions/comments: This problem also supplies solutions. See http://www.ncbi.nlm.nih.gov/books/NBK179288/ for help in setting up and using EDirect on any platform.

[6-4] We described how ClustalW applies a correction factor to downweight the influence of closely related proteins. Test the performance of ClustalW: take the globins in web documents 6.1 and/or 6.2 and align. Then repeat the alignment with the additional input one divergent sequence repeated varying number of times. For example, in the closely related group of beta globins, add five copies of the chicken sequence to see its influence on the alignment.

Solutions/comments: Here is a set of distantly related globins; you can choose this or another data set, but it is helpful to include some distantly related proteins. >beta_globin 2hhbB NP_000509.1 [Homo sapiens] MVHLTPEEKSAVTALWGKVNVDEVGGEALGRLLVVYPWTQRFFESFGDLSTPDAVMGNPKVKAHGKKVLG AFSDGLAHLDNLKGTFATLSELHCDKLHVDPENFRLLGNVLVCVLAHHFGKEFTPPVQAAYQKVVAGVAN ALAHKYH >myoglobin 2MM1 NP_005359.1 [Homo sapiens] MGLSDGEWQLVLNVWGKVEADIPGHGQEVLIRLFKGHPETLEKFDKFKHLKSEDEMKASEDLKKHGATVL TALGGILKKKGHHEAEIKPLAQSHATKHKIPVKYLEFISECIIQVLQSKHPGDFGADAQGAMNKALELFR KDMASNYKELGFQG >neuroglobin 1OJ6A NP_067080.1 [Homo sapiens] MERPEPELIRQSWRAVSRSPLEHGTVLFARLFALEPDLLPLFQYNCRQFSSPEDCLSSPEFLDHIRKVML VIDAAVTNVEDLSSLEEYLASLGRKHRAVGVKLSSFSTVGESLLYMLEKCLGPAFTPATRAAWSQLYGAV VQAMSRGWDGE >soybean_globin 1FSL P02238 LGBA_SOYBN [Glycine max] MVAFTEKQDALVSSSFEAFKANIPQYSVVFYTSILEKAPAAKDLFSFLANGVDPTNPKLTGHAEKLFALV RDSAGQLKASGTVVADAALGSVHAQKAVTDPQFVVVKEALLKTIKAAVGDKWSDELSRAWEVAYDELAAA 90 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) IKKA >rice_globin 1D8U rice Non-Symbiotic Plant Hemoglobin NP_001049476.1 [Oryza sativa (japonica cultivar-group)] MALVEDNNAVAVSFSEEQEALVLKSWAILKKDSANIALRFFLKIFEVAPSASQMFSFLRNSDVPLEKNPK LKTHAMSVFVMTCEAAAQLRKAGKVTVRDTTLKRLGATHLKYGVGDAHFEVVKFALLDTIKEEVPADMWS PAMKSAWSEAYDHLVAAIKQEMKPAE Align them with ClustalW2 at EBI (http://www.ebi.ac.uk/Tools/msa/clustalw2/) with default settings:

Note the insertion in rice globin (corresponding to a gap in the other four proteins) about halfway though the alignment. Add extra copies of neuroglobin (same sequence, unique names, in this case neuroglobin2, neuroglobin3, neuroglobin4): >beta_globin 2hhbB NP_000509.1 [Homo sapiens] MVHLTPEEKSAVTALWGKVNVDEVGGEALGRLLVVYPWTQRFFESFGDLSTPDAVMGNPKVKAHGKKVLG AFSDGLAHLDNLKGTFATLSELHCDKLHVDPENFRLLGNVLVCVLAHHFGKEFTPPVQAAYQKVVAGVAN ALAHKYH >myoglobin 2MM1 NP_005359.1 [Homo sapiens] MGLSDGEWQLVLNVWGKVEADIPGHGQEVLIRLFKGHPETLEKFDKFKHLKSEDEMKASEDLKKHGATVL TALGGILKKKGHHEAEIKPLAQSHATKHKIPVKYLEFISECIIQVLQSKHPGDFGADAQGAMNKALELFR KDMASNYKELGFQG >neuroglobin 1OJ6A NP_067080.1 [Homo sapiens] MERPEPELIRQSWRAVSRSPLEHGTVLFARLFALEPDLLPLFQYNCRQFSSPEDCLSSPEFLDHIRKVML VIDAAVTNVEDLSSLEEYLASLGRKHRAVGVKLSSFSTVGESLLYMLEKCLGPAFTPATRAAWSQLYGAV VQAMSRGWDGE >neuroglobin2 MERPEPELIRQSWRAVSRSPLEHGTVLFARLFALEPDLLPLFQYNCRQFSSPEDCLSSPEFLDHIRKVML VIDAAVTNVEDLSSLEEYLASLGRKHRAVGVKLSSFSTVGESLLYMLEKCLGPAFTPATRAAWSQLYGAV VQAMSRGWDGE >neuroglobin3 MERPEPELIRQSWRAVSRSPLEHGTVLFARLFALEPDLLPLFQYNCRQFSSPEDCLSSPEFLDHIRKVML VIDAAVTNVEDLSSLEEYLASLGRKHRAVGVKLSSFSTVGESLLYMLEKCLGPAFTPATRAAWSQLYGAV VQAMSRGWDGE >neuroglobin4 MERPEPELIRQSWRAVSRSPLEHGTVLFARLFALEPDLLPLFQYNCRQFSSPEDCLSSPEFLDHIRKVML 91 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) VIDAAVTNVEDLSSLEEYLASLGRKHRAVGVKLSSFSTVGESLLYMLEKCLGPAFTPATRAAWSQLYGAV VQAMSRGWDGE >soybean_globin 1FSL leghemoglobin P02238 LGBA_SOYBN [Glycine max] MVAFTEKQDALVSSSFEAFKANIPQYSVVFYTSILEKAPAAKDLFSFLANGVDPTNPKLTGHAEKLFALV RDSAGQLKASGTVVADAALGSVHAQKAVTDPQFVVVKEALLKTIKAAVGDKWSDELSRAWEVAYDELAAA IKKA >rice_globin 1D8U rice Non-Symbiotic Plant Hemoglobin NP_001049476.1 [Oryza sativa (japonica cultivar-group)] MALVEDNNAVAVSFSEEQEALVLKSWAILKKDSANIALRFFLKIFEVAPSASQMFSFLRNSDVPLEKNPK LKTHAMSVFVMTCEAAAQLRKAGKVTVRDTTLKRLGATHLKYGVGDAHFEVVKFALLDTIKEEVPADMWS PAMKSAWSEAYDHLVAAIKQEMKPAE

Re-analyze in Clustal2W:

Carefully inspect the region surrounding the main internal extension (of rice globin) and note that the alignment has now changed. Further note the gap in the first alignment, beginning of the middle block, included for soybean T--N. This region has been aligned quite differently in the second data set having additional . Given that this exercise showed that additional sequences changed the alignment, how can you decide which is “better”? One main answer is that we can use benchmarking to decide which alignments are better supported by structural information. Another possibility is to obtain a large set of homologs (e.g. 50 or 100 rather than 5) and gain stronger evidence of where the gap positions occur in nature. Another possibility is to use phylogeny-aware alignment strategies as discussed in the chapter. 92 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [6-5] Use the T-Coffee programs to evaluate the effect of structural information on your alignments. Follow these steps. (1) Obtain a group of five distantly related lipocalins from web document 6.10 (►http://www.bioinfbook.org/chapter6). These include rat odorant-binding protein, and human retinol-binding protein. (2) Align the sequences using T-Coffee (►http://www.tcoffee.org/) (WebLink 6.13), or use another program. (3) Evaluate the alignment with the iRMSD program (►http://www.tcoffee.org/). Include the information on two known lipocalin structures. Note the score. (4) Align the same sequences again using Expresso (►http://www.tcoffee.org/) to incorporate structural information. Note the score. Did it improve? Do the alignments differ?

Solutions/comments: Here are eight lipocalins: >human_RBP4 gi|55743122|ref|NP_006735.2| retinol-binding protein 4, plasma precursor [Homo sapiens] MKWVWALLLLAALGSGRAERDCRVSSFRVKENFDKARFSGTWYAMAKKDPEGLFLQDNIVAEFSVDETGQ MSATAKGRVRLLNNWDVCADMVGTFTDTEDPAKFKMKYWGVASFLQKGNDDHWIVDTDYDTYAVQYSCRL LNLDGTCADSYSFVFSRDPNGLPPEAQKIVRQRQEELCLARQYRLIVHNGYCDGRSERNLL >rat_OBP gi|20302101|ref|NP_620258.1| odorant binding protein I f [Rattus norvegicus] MVKFLLIVLALGVSCAHHENLDISPSEVNGDWRTLYIVADNVEKVAEGGSLRAYFQHMECGDECQELKII FNVKLDSECQTHTVVGQKHEDGRYTTDYSGRNYFHVLKKTDDIIFFHNVNVDESGRRQCDLVAGKREDLN KAQKQELRKLAEEYNIPNENTQHLVPTDTCNQ >NP_006735 retinol-binding protein 4 [Homo sapiens] MKWVWALLLLAALGSGRAERDCRVSSFRVKENFDKARFSGTWYAMAKKDPEGLFLQDNIVAEFSVDETGQ MSATAKGRVRLLNNWDVCADMVGTFTDTEDPAKFKMKYWGVASFLQKGNDDHWIVDTDYDTYAVQYSCRL LNLDGTCADSYSFVFSRDPNGLPPEAQKIVRQRQEELCLARQYRLIVHNGYCDGRSERNLL >1QWD|A Bacterial Lipocalin Blc E. Coli MSYYHHHHHHLESTSLYKKSSSTPPRGVTVVNNFDAKRYLGTWYEIARFDHRFERGLEKVTATYSLRDDG GLNVINKGYNPDRGMWQQSEGKAYFTGAPTRAALKVSFFGPFYGGYNVIALDREYRHALVCGPDRDYLWI LSRTPTISDEVKQEMLAVATREGFDVSKFIWVQQPGS >1Z24|A Chain A, The Molecular Structure Of Insecticyanin From The Tobacco Hornworm Manduca Sexta L. At 2.6 A Resolution. GDIFYPGYCPDVKPVNDFDLSAFAGAWHEIAKLPLENENQGKCTIAEYKYDGKKASVYNSFVSNGVKEYM EGDLEIAPDAKYTKQGKYVMTFKFGQRVVNLVPWVLATDYKNYAINYNCDYHPDKKAHSIHAWILSKSKV LEGNTKEVVDNVLKTFSHLIDASKFISNDFSEAACQYSTTYSLTGPDRH >2BLG Bovine Beta-Lactoglobulin LIVTQTMKGLDIQKVAGTWYSLAMAASDISLLDAQSAPLRVYVEELKPTPEGDLEILLQKWENDECAQKK IIAEKTKIPAVFKIDALNENKVLVLDTDYKKYLLFCMENSAEPEQSLVCQCLVRTPEVDDEALEKFDKAL KALPMHIRLSFNPTQLEEQCHI >1PBO|A Bovine Odorant Binding Protein (Obp) AQEEEAEQNLSELSGPWRTVYIGSTNPEKIQENGPFRTYFRELVFDDEKGTVDFYFSVKRDGKWKNVHVK ATKQDDGTYVADYEGQNVFKIVSLSRTHLVAHNINVDKHGQKTELTGLFVKLNVEDEDLEKFWKLTEDKG IDKKNVVNFLENEDHPHPE >1E5P|A Aphrodisin Female Hamster QDFAELQGKWYTIVIAADNLEKIEEGGPLRFYFRHIDCYKNCSEXEITFYVITNNQCSKTTVIGYLKGNG TYETQFEGNNIFQPLYITSDKIFFTNKNXDRAGQETNXIVVAGKGNALTPEENEILVQFAHEKKIPVENI LNILATDTCPE Analyze them using TCoffee (http://www.tcoffee.org):

93 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The T-Coffee output:

94 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [6-6] MAFFT was developed as a command-line program. This problem introduces you to using MAFFT in the Linux environment. In particular, we will obtain a set of alpha globin proteins and a set of beta globin proteins, align them, and then align the two profiles. (1) First obtain the globins by searching NCBI’s HomoloGene resource with the term globin. The beta globin group (HomoloGene:68066) currently includes 15 proteins. Click the download link and save them as a text file. Repeat this for 14 proteins in the “hemoglobin, alpha 2” family (HomoloGene:469; all proteins have a length of 142 residues). These files are given as Web Documents 6.11 and 6.12, and the entries are conveniently renamed in Web Documents 6.13 and 6.14. (2) Open a Linux terminal session, and create two new documents: vim hba.fasta (paste your sequences into the editor, then use :wq to write the file and quit) and vim hbb.fasta. Alternatively, if you are working on a PC use WinSCP or a similar utility to transfer a text file to your working directory. (3) Perform alignments as described in this chapter for the command- line MAFFT.

Solutions/comments: Visit the MAFFT homepage (http://mafft.cbrc.jp/alignment/software/) and download the software.

The chapter includes instructions for running MAFFT on the command line.

[6-7] The purpose of this problem is to obtain mammalian DNA sequences in the beta globin region and align them. (1) Visit the UCSC Genome Browser (build GRCh37) position chr11:5,245,001-5,295,000. This 50 kilobase region of chromosome 11p15.4 includes the RefSeq genes HBB, HBD, HBBP1, HBG1, HBG2, and HBE1. (2) In the Comparative Genomics section click the header for the “Conservation” track. Download the sequences. (You can also download multiple alignments of 45 vertebrate genomes with human [from http://hgdownload.soe.ucsc.edu/downloads.html]. As another example to try, obtain a MAF file from http://hgdownload.soe.ucsc.edu/goldenPath/hg19/multiz46way/maf/ and browse to

95 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) chrM.maf.gz (252K) for an example of a small set of sequences.) (3) Analyze multiple alignments in MAFFT as described above.

Solutions/comments: Visit UCSC and enter the coordinates:

Note the conservation track under Comparative Genomics:

By selecting “conservation” you can reach a link to download multiple alignments:

An portion of the download page from the MAF link (http://hgdownload.cse.ucsc.edu/goldenPath/hg19/multiz100way/) is here:

96 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Return to the Conservation track settings. At the top, select “full” as follows:

In the middle section, select species of interest. Lower down, add the settings to display alignments:

Click submit and the resulting browser view is shown here, including Multiz alignments:

Click the track labeled “Rhesus” and obtain a view of the alignment blocks, such as the following (partial) list of species with aligned sequences. 97 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) You can further follow the link to download the DNA of the multiple alignment, or view a particular alignment block back in the Genome Browser.

[6-8]. This problem introduces multiple alignments in the MAF format at the Galaxy website. Go to Galaxy (either the main public server or a local instance you set up). (2) Under the “Get Data” tool (left sidebar), select UCSC Main table browser. Choose mammal, human, Feb. 2009 (GRCh37/hg19), Genes and Gene Prediction Tracks (group), RefSeq Genes (track), and in the position box type in hbb then “lookup” to obtain the coordinates chr11:5246696-5248301. Use the output format “BED” and send the output to Galaxy. (3) View the dataset. (4) Go to Tools > Fetch Alignments > Extract MAF blocks. For the interval, use the imported data set from the UCSC table browser; for MAF source, choose “Locally Cached Alignments”; and select “46-way multiZ (hg19).” (5) Inspect the output (click the eye icon on the history panel). There are 37 blocks across this region. For each block, the line labeled “a” shows a float point score, while the lines labeled “s” correspond to sequences (these are 0-based starts). (6) On the tools panel choose “Graph/ Display Data” then choose GMAJ. This is an interactive, Java-based multiple alignment viewer (Blanchette et al., 2004). (7) Convert the multiple alignment to a set of FASTA files. Go to Tools > Convert Formats > “MAF to FASTA” and choose one sequence per species as the type of FASTA output. Optionally you can download these sequences (e.g. to align them with different methods). For example, you can use Tools > Multiple Alignments > ClustalW to align these FASTA files. (8) Choose Tools > Evolution > “Neigbor Joining Tree Builder”. Use the FASTA file, and a distance model such as Kimura 2 parameter (see Chapter 7). (9) Choose Tools > Fetch Alignments > MAF Coverage Stats. Using the summarized coverage output option, the coverage is the number of nucleotides divided by total length of the given intervals. 98 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Solutions/comments: The “Get data” tool (at left sidebar) is shown including a link to the UCSC Table Browser:

The Table Browser settings are as follows; note the output is BED and the option “send output to Galaxy” is selected:

At the next page select whole gene. The Galaxy output is gray while waiting for the job to queue:

The output (in the history pane, right sidebar) is yellow while waiting for the job to complete:

99 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The output is green when ready; click it to expand, and click the eye icon to display information in the central display panel:

Follow the instructions to Tools > Fetch Alignments > Extract MAF blocks (on the left sidebar), the Execute.

100 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Here the output includes 213 blocks:

Note the GMAJ viewer (on the left sidebar); click. Note this requires Java. Next use the MAF to FASTA converter:

101 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The result is that a series of FASTA formatted sequences are returned, corresponding to aligned portions of the beta globin region across the species that are selected. A screen capture shows this:

[6-9] The goal of this exercise is to understand genomic alignments available at Ensembl. We will use a Linux machine. (1) Visit the Ensembl website (http://useast.ensembl.org/Homo_sapiens/Info/Index) for Human (build GRCh37). There is a comparative genomics section with information about comparative analyses as well as downloads (ftp://ftp.ensembl.org/pub/release-71/emf/ensembl-compara/). Visiting that ftp site we see directories for various groups of vertebrates. We will select a folder called homologies (ftp://ftp.ensembl.org/pub/release-71/emf/ensembl-compara/homologies/). It has five protein files. (2) We’ll download the first file with the wget command:

102 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) $ wget ftp://ftp.ensembl.org/pub/release-71/emf/ensembl- compara/homologies/Compara.71.protein.aa.fasta.gz This is 226 MB in size (as shown with the ls –lh command) and is a .gz (compressed) file. We unzip using the command gunzip Compara.71.protein.aa.fasta.gz and the resulting uncompressed file, called Compara.71.protein.aa.fasta, is large (1.6 GB in size). To see how many lines are in this file, type wc –l Compara.71.protein.aa.fasta (there are 29,337,499 rows). These are FASTA protein records with headers beginning with >ENSEEUP00000006240. Explore these. (3) Use wget ftp://ftp.ensembl.org/pub/release-71/emf/ensembl-compara/hom ologies/Compara.71.protein.cds.fasta.gz to obtain the coding sequence alignment for every protein_tree in FASTA format (this 565 MB file uncompresses to 4.8 GB). It contains nucleotide FASTA records (beginning with >ENSEEUP00000006240, corresponding to the hedgehog ZNF235 gene).

Solutions/comments: As of August 2015 the links mentioned in this problem are stable. For example, visit ftp://ftp.ensembl.org/pub/release-71/emf/ensembl-compara/homologies/ and connect to the Ensembl FTP server as a guest. An example of the downloaded files is here:

The problem calls for Linux but can be studied with the Mac terminal (a Unix-like environment) and possibly with Cygwin on a PC.

103 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) Solutions to problems: Chapter 7 Moleclar Phylogeny and Evolution

[7.1] Determine whether human and chimpanzee mitochondrial DNA sequences have equal evolutionary rates between lineages. To do this, use Tajima’s relative rate test as implemented in MEGA. [1] Obtain MEGA software. [2] Obtain mitochondrial DNA sequences from human, chimpanzee, bonobo, orangutan, gorilla, and gibbon from Web Document 7.19 at ►http://www.bioinfbook.org/chapter7. [3] Apply Tajima’s test using an appropriate outgroup. Is the probability value significant (<0.05)?

Solutions/comments: MEGA software is available from http://www.megasoftware.net.

[7.2] Perform phylogenetic analyses using MEGA software. (1) Go to the conserved domain Database (http://www.ncbi.nlm.nih.gov/cdd) at NCBI. (2) Enter lipocalins (or another family of your choice; you can also begin at Ensembl, HomoloGene, or Pfam). (3) Select the mFasta format then click “Reformat.” The result is a multiple sequence alignment. Copy this into a text editor (such as NotePad++), and simplify the names of the sequences. (4) Import the file (or paste the sequences) into MEGA as shown in Fig. 7.9. Align the sequences, save in the .mas and .meg formats. (5) Choose Phylogeny > Construct/Test to create neighbor-joining, maximum likelihood, or other trees. (6) For each tree you create, read the caption. Try the tree tools (e.g. placing a root, flipping nodes, showing or hiding branch lengths, interconverting display formats). (7) Perform bootstrapping. Identify clades having low levels of support. Why does this occur?

Solutions/comments: From the home page of NCBI enter lipocalin; follow the link of the search results to conserved domains; view the result.

104 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The sequence data in the mFasta format are as follows: >gi|260656184|pdb|3EYC|D ------asdeeiqdvSGTWYLKAMTVdrefpEMNLE--SVTPMTLTTL-EGGNLE AKVTMLISGR--CQEVKAVLEKTDEPGKYTA------DGGKHVAYIIRSHVKDHYIFYSEGELHG-K-PVRGVKLVGRD PKNNLEAledFEKAAGARGLSTESILIPRQSEtcspgsawshpqfek------>gi|81904828|sp|Q9D265|Q9D265_MOUSE ------mqfQGEWFVLGLADnt-frREHRAllNFFTTLFELK-EKSQFQ VTNSMTRGKH--CNTWSYTLIPATKPGQFTRdnrgsgpGADRENIQVIETDYITFALVLSLRQTSs-Q-NITRVSLLGRN WRLSHKTidkFICLTRTQNLTKDNFLFPDLSDwlpdpqvc------>gi|347948626|pdb|3S26|A ------qdstqnlipapslltvplqpdfrsdqfRGRWYVVGLAGna-vqKKTEGsfTMYSTIYELQ-ENNSYN VTSILVRDQDqgCRYWIRTFVPSSRAGQFTLgnmhrypQVQSYNVQVATTDYNQFAMVFFRKTSENkQ-YFKI-TLYGRT KELSPELkerFTRFAKSLGLKDDNIIFSVPTDqcidnsawshpqfek------>gi|60593960|pdb|1X71|B ------qdstsdlipapplskvplqqnfqdnqfQGKWYVVGLAGna-ilREDKDpqKMYATIYELK-EDKSYN VTSVLFRKKK--CDYWIRTFVPGSQPGEFTLgniksypGLTSYLVRVVSTNYNQHAMVFFKKVSQNrE-YFKI-TLYGRT KELTSELkenFIRFSKSLGLPENHIVFPVPIDqcidg------>gi|82123701|sp|O93588|O93588_LACVV ------lvfgmtpdyifpvsadipvvpnfdpqktVGKWHPIGMASklpelTPYEQkiSPMDHIVEV--IDGDMK LTANYMSDGV--SKEATAMLKHTDKPGVFKFt------DGEVHVLDVDFEKYIMLYVKKS------SHEALFLSARG PDVEDDIkekFKKLVLEQSFPEANIKYFNAEQctptaa------105 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) ------>gi|82071154|sp|O93589|O93589_LACVV ------mtpdyifpvsadipvvanfdtpktVGKWHPIGMASklpelTPYEQkiSPMDHIVEV--TDGDMK LTANYMSDGV--CKTSVLVLKHTDKPGVFKVp------DGEVHVIKMLILKSISFFTSKk----P-THEALFLSARG STGGDDIkakFKKLVWEQIILEAHIKYLNVEQctpkag------>gi|190359792|sp|A2AJB7.1|LCN5_MOUSE mcsvarhmesimlftllglcvglaagteaavvkdfdvnkfLGFWYEIALASkmgayGLAHKeeKMGAMVVEl--KENLLA LTTTYYNEGH--CVLEKVAATQVDGSAKYKVt-----rISGEKEVVVVATDYMTYTVIDITSLVAg-A-VHRAMKLYSRS LDNNGEAlnnFQKIALKHGFSETDIHILKHDLtcvnalqsgqi------>gi|2506821|sp|P00978.2|AMBP_BOVIN mrslsgllllltaclavnassvptlpddiqvqenfdlsriYGKWFNVAVGStcpwlKRFKEkmTMSTVVLIAGpTSKEIS VTNTHRRKGV--CESISGTYEKTSADGKFLYhk---akWNITMESYVVHTNYDEYAIFLTKKLSRRhG-PTITVKLYGRE PQLRESLleeFREVALGVGIPEDAIFTMPDRGecvpgeqdpvptplsrarravltqeeegsgagqpvtnfskkadscqld ysqgpclglfkryfyngtsmacetflyggcmgngnnflsekeclqtcrtveacnlpivqgpcrsyiqlwafdavkgkcvr fsyggckgngnkfysekeckeycgipgeadeellrfsn >gi|172046756|sp|Q07456.2|AMBP_MOUSE -mqglrtlfllltaclasradpastlpdiqvqenfsesriYGKWYNLAVGStcpwlSRIKDkmSVSTLVLQEGaTETEIS MTSTRWRRGV--CEEITGAYQKTDIDGKFLYhk---skWNITLESYVVHTNYDEYAIFLTKKSSHh-HgLTITAKLYGRE PQLRDSLlqeFKDVALNVGISENSIIFMPDRGecvpgdreveptsiararravlpqesegsgteplitgtlkkedscqln ysegpclgmqeryyyngasmacetfqyggclgngnnfisekdclqtcrtiaacnlpivqgpcrafiklwafdaaqgkciq fhyggckgngnkfysekeckeycgvpgdgyeelirs-- >gi|374977533|pdb|3QKG|A ------gpvptppdniqvqenfnisriYGKWYNLAIGStspwlKKIMDrmTVSTLVLGEGaTEAEIS MTSTRWRKGV--CEETSGAYEKTDTDGKFLYhk---skWNITMESYVVHTNYDEYAIFLTKKFSRHhG-PTITAKLYGRA PQLRETLlqdFRVVAQGVGIPEDSIFTMADRGecvpgeqepepiliprsawshpqfek------Adjust the file names to make them more informative. You can look up a string of identifiers using BioMart, or biomaRt, or EDirect, or by entering a string at once into an NCBI web search. >human_tear_lipocalin ------asdeeiqdvSGTWYLKAMTVdrefpEMNLE--SVTPMTLTTL-EGGNLE AKVTMLISGR--CQEVKAVLEKTDEPGKYTA------DGGKHVAYIIRSHVKDHYIFYSEGELHG-K-PVRGVKLVGRD PKNNLEAledFEKAAGARGLSTESILIPRQSEtcspgsawshpqfek------>mouse_allergen ------mqfQGEWFVLGLADnt-frREHRAllNFFTTLFELK-EKSQFQ VTNSMTRGKH--CNTWSYTLIPATKPGQFTRdnrgsgpGADRENIQVIETDYITFALVLSLRQTSs-Q-NITRVSLLGRN WRLSHKTidkFICLTRTQNLTKDNFLFPDLSDwlpdpqvc------>mouse_siderocalin ------qdstqnlipapslltvplqpdfrsdqfRGRWYVVGLAGna-vqKKTEGsfTMYSTIYELQ-ENNSYN VTSILVRDQDqgCRYWIRTFVPSSRAGQFTLgnmhrypQVQSYNVQVATTDYNQFAMVFFRKTSENkQ-YFKI-TLYGRT KELSPELkerFTRFAKSLGLKDDNIIFSVPTDqcidnsawshpqfek------>human_siderocalin ------qdstsdlipapplskvplqqnfqdnqfQGKWYVVGLAGna-ilREDKDpqKMYATIYELK-EDKSYN VTSVLFRKKK--CDYWIRTFVPGSQPGEFTLgniksypGLTSYLVRVVSTNYNQHAMVFFKKVSQNrE-YFKI-TLYGRT KELTSELkenFIRFSKSLGLPENHIVFPVPIDqcidg------> lizard_Androgen-regulated epipidymal secretory protein ------lvfgmtpdyifpvsadipvvpnfdpqktVGKWHPIGMASklpelTPYEQkiSPMDHIVEV--IDGDMK 106 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) LTANYMSDGV--SKEATAMLKHTDKPGVFKFt------DGEVHVLDVDFEKYIMLYVKKS------SHEALFLSARG PDVEDDIkekFKKLVLEQSFPEANIKYFNAEQctptaa------> lizard2_Androgen-regulated epipidymal secretory protein ------mtpdyifpvsadipvvanfdtpktVGKWHPIGMASklpelTPYEQkiSPMDHIVEV--TDGDMK LTANYMSDGV--CKTSVLVLKHTDKPGVFKVp------DGEVHVIKMLILKSISFFTSKk----P-THEALFLSARG STGGDDIkakFKKLVWEQIILEAHIKYLNVEQctpkag------>mouse_Epididymal retinoic acid-binding protein mcsvarhmesimlftllglcvglaagteaavvkdfdvnkfLGFWYEIALASkmgayGLAHKeeKMGAMVVEl--KENLLA LTTTYYNEGH--CVLEKVAATQVDGSAKYKVt-----rISGEKEVVVVATDYMTYTVIDITSLVAg-A-VHRAMKLYSRS LDNNGEAlnnFQKIALKHGFSETDIHILKHDLtcvnalqsgqi------>bovine_Alpha-1-microglobulin mrslsgllllltaclavnassvptlpddiqvqenfdlsriYGKWFNVAVGStcpwlKRFKEkmTMSTVVLIAGpTSKEIS VTNTHRRKGV--CESISGTYEKTSADGKFLYhk---akWNITMESYVVHTNYDEYAIFLTKKLSRRhG-PTITVKLYGRE PQLRESLleeFREVALGVGIPEDAIFTMPDRGecvpgeqdpvptplsrarravltqeeegsgagqpvtnfskkadscqld ysqgpclglfkryfyngtsmacetflyggcmgngnnflsekeclqtcrtveacnlpivqgpcrsyiqlwafdavkgkcvr fsyggckgngnkfysekeckeycgipgeadeellrfsn >mouse_Alpha-1-microglobulin -mqglrtlfllltaclasradpastlpdiqvqenfsesriYGKWYNLAVGStcpwlSRIKDkmSVSTLVLQEGaTETEIS MTSTRWRRGV--CEEITGAYQKTDIDGKFLYhk---skWNITLESYVVHTNYDEYAIFLTKKSSHh-HgLTITAKLYGRE PQLRDSLlqeFKDVALNVGISENSIIFMPDRGecvpgdreveptsiararravlpqesegsgteplitgtlkkedscqln ysegpclgmqeryyyngasmacetfqyggclgngnnfisekdclqtcrtiaacnlpivqgpcrafiklwafdaaqgkciq fhyggckgngnkfysekeckeycgvpgdgyeelirs-- >human_Alpha-1-microglobulin ------gpvptppdniqvqenfnisriYGKWYNLAIGStspwlKKIMDrmTVSTLVLGEGaTEAEIS MTSTRWRKGV--CEETSGAYEKTDTDGKFLYhk---skWNITMESYVVHTNYDEYAIFLTKKFSRHhG-PTITAKLYGRA PQLRETLlqdFRVVAQGVGIPEDSIFTMADRGecvpgeqepepiliprsawshpqfek------Paste the sequences into MEGA (or upload a text file with the file extension myfile.fasta). The alignment explorer of MEGA shows the imported multiple alignment from NCBI’s Conserved Domain Database. Here note the asterisks mark 100% conservation of amino acid sequence in a given column; the GXW motif is evident.

Choose Phylogeny (top menu) and select the method of tree construction (e.g. neighbor-joining):

107 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The analysis preferences dialog allows you to select a variety of parameters of the analysis, such as bootstrapping (under “phylogeny test”).

Example of a neighbor-joining tree made in MEGA:

108 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) The MEGA tree view includes an option to display the caption:

T

109 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) [7.3] Perform Bayesian inference of phylogeny using MrBayes software. A detailed analysis for 13 globin proteins is provided in web documents 7.17 and 7.18. Use a group of proteins, and also perform an analysis for DNA coding sequences from a group of myoglobins (and as an outgroup; provided in web document 7.5).

Solutions/comments: You can obtain MrBayes software from http://mrbayes.sourceforge.net. On a Mac, visit the Downloads directory and double-click on the .pkg installation icon. The program is installed in /usr/local/bin. Open a terminal session and type mb to start the program:

From here perform phylogenetic analysis as described in Chapter 7. For example, type execute mydata.nex for DNA or protein sequences in the Nexus format. For more information, find the documentation and examples. We change directory (cd) to the MrBayes folder in the /Applications directory. We list files (ls) in the long, human-readable (-lh) format. This shows us that there is a directory (see the letter d at the left of the line) called examples. We cd into that directory, list the files, and see there are 7 Nexus files we can use for our analyses. Word count (wc) of the lines (-l) shows us that the primates.nexus file has 22 rows, and exploring these shows they are mitochondrial sequences we can use.

110 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) As a specific example, navigate to the directory in which you would like to work, copy the nexus files there, and you are ready to enter $ mb to begin the MrBayes program:

Here ~ indicates the home directory and I include a path to a folder where I am doing my analyses. The copy command (cp) is used to copy all the files that end with the suffix .nex from the MrBayes examples folder; the . indicates that these files should be transferred to the present directory. The ls *.nex command lists all the files in my working directory, confirming that they have been successfully copied here.

[7.5] For students interested in Python, explore the ETE programming toolkit for the automated manipulation, analysis, and visualization of phylogenetic trees. The website ►http://pythonhosted.org/ete2/ (WebLink 7.28) includes documentation, access to ETE, and a tutorial.

Solutions/comments: Working on a Mac, Python is installed by default. Open a terminal window and type python:

111 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.) As indicated, my version is Python 2.7.9; you may prefer a more recent version. Working on a PC, I recommend that you install IDLE, an excellent interface. The ETE website (http://etetoolkit.org/docs/2.3/) includes detailed installation directions for Linux, Mac, and PC (see http://etetoolkit.org/download/). The ETS site also includes a detailed tutorial.

112 Jonathan Pevsner Solutions to Problems (c) 2015 Bioinformatics & Functional Genomics (3d Ed.)