Skip to content
naulon

No retraction, correction or concern found when last checked on Oct 17, 2026.

Skylign: a tool for creating informative, interactive logos representing sequence alignments and profile hidden Markov models

Travis J Wheeler, Jody Clements, Robert D Finn

BMC Bioinformatics · 2014

doi:10.1186/1471-2105-15-7

Abstract

Background. Logos are commonly used in molecular biology to provide a compact graphical representation of the conservation pattern of a set of sequences. They render the information contained in sequence alignments or profile hidden Markov models by drawing a stack of letters for each position, where the height of the stack corresponds to the conservation at that position, and the height of each letter within a stack depends on the frequency of that letter at that position.

Results. We present a new tool and web server, called Skylign, which provides a unified framework for creating logos for both sequence alignments and profile hidden Markov models. In addition to static image files, Skylign creates a novel interactive logo plot for inclusion in web pages. These interactive logos enable scrolling, zooming, and inspection of underlying values. Skylign can avoid sampling bias in sequence alignments by down-weighting redundant sequences and by combining observed counts with informed priors. It also simplifies the representation of gap parameters, and can optionally scale letter heights based on alternate calculations of the conservation of a position.

Conclusion. Skylign is available as a website, a scriptable web service with a RESTful interface, and as a software package for download. Skylign’s interactive logos are easily incorporated into a web page with just a few lines of HTML markup. Skylign may be found at http://skylign.org.

Full text

From PubMed Central, U.S. National Library of Medicine, as current on Oct 17, 2026. Paragraph numbers are ours, so an answer can point at one.

Alignments and profile hidden Markov models

Alignments of multiple biological sequences play an important role in a wide range of bioinformatics applications, and are used to represent sequence families that range in size from DNA binding site motifs to full length proteins, ribosomal RNAs, and autonomous transposable elements. In an alignment, sequences are organized such that each column contains amino acids (or nucleotides) related by descent or shared functional constraint. The distributions of letters will typically vary from column to column. These patterns can reveal important characteristics of the sequence family, for example highlighting sites vital to conformation or ligand binding.

A sequence alignment can be used to produce a profile hidden Markov model (profile HMM). Profile HMMs provide a formal probabilistic framework for sequence comparison, leveraging the information contained in a sequence alignment to improve detection of distantly related sequences. They are, for example, used in the annotation of both protein domains and genomic sequence derived from ancient transposable element expansions.

Consider a family of related sequences, and an alignment of a subset of those sequences. For each column, we can think of the observed letters as having been sampled from the distribution, of letters at that position among all members of the sequence family. One approach to estimating for a column is to compute a maximum likelihood estimate directly from observed counts at that column. An alternative is to try to improve the estimate using sequence weighting (relative and absolute) and mixture Dirichlet priors. The later approach is used in computing position-specific letter distributions for profile HMMs.

In an alignment, a subset of the columns will be consensus columns, in which most sequences are represented by a letter, rather than a gap character. In a typical profile HMM, a model position is created for each consensus column, and non-consensus columns are treated as insertions relative to model positions. As with letters, the per-position gap distributions may be estimated from observed or weighted counts, or combined with a Dirichlet prior.

Logos

A logo provides a compact graphical representation of an alignment, representing each column with a stack of letters. The total height of each stack corresponds to a measure of the invariance of the column – typically, it is the information content of that position. The height of each letter within a stack depends on the frequency of that letter at that position. Logos were originally devised to represent the extent of letter conservation in each column of an alignment, and were later generalized to show letter and gap probabilities of a profile HMM.

Consider an alphabet A consisting of L letters, a1 through a L (L is 4 for DNA, and 20 for amino acids). For a given column in an alignment, we capture the estimated column distribution as a length-L vector, such that p i is the probability of observing letter a i at that column. We define the length-L vector to be the background distribution over letters in A, such that q i is the background probability of observing letter a i, typically based on letter frequency in a large set of representative sequences.

Given and, the information content of the column, also called relative entropy or Kullback–Leibler distance, is defined as:

When the base of the log is 2, the information content is expressed in bits. This value indicates the extent to which a column’s distribution differs from the background, and serves as a measure of the conservation of the column. Information content is non-negative, largest when a column is invariant, and especially large when the invariant letter is rare in. For example, the maximum information content for one column in a DNA alignment under uniform background distribution is 2 bits. The maximum for an amino acid alignment under the background corresponding to the BLOSUM62 scoring matrix is roughly 6.5 bits – this for an invariant column of Tryptophan, which has the lowest background probability. Table 1 shows examples of information content values for a few DNA letter distributions, to give some insight into the complex relationship between information content and letter frequencies.

For a conventional logo, a stack’s height is spread among the letters in alphabet A based on, such that the height of each letter a i within a stack is. Letters are sorted such that those with larger p i appear near the top in the stack. An example is shown in Figure 1.

Implementation

We present a software tool and associated web service, called Skylign, which offers several advantages over existing logo tools. It can generate both a static image file and a new interactive web plot that supports scrolling, zooming, and inspection of values underlying each letter stack. Skylign also produces a simplified representation of per-position gap probabilities, and optionally reduces visual clutter by including only overrepresented letters in a stack. Skylign’s interactive logos are robust and fast for alignments with length in the thousands, such as those representing many transposable element families.

An important implementation detail is that Skylign produces logos for both profile HMMs and multiple sequence alignments in a unified framework. Profile logos are plotted using the per-position distributions of the profile HMM. For alignment logos, the column distributions can be estimated either from observed counts, weighted counts, or based on posterior probabilities after combining with a Dirichlet mixture prior. Estimation based on weights and priors is performed by explicitly producing a profile HMM using the hmmbuild tool within HMMER3.1.

In the following sections, we describe implementation details, compare alternative visualization approaches, and illustrate the utility of these logos. Skylign can be accessed as a web service at http://skylign.org, and the Skylign software package may be downloaded for independent installation.

Results and discussion

Several logo web servers have been released since the introduction of logos, each with their own enhancements to logo presentation. In the course of developing websites for sequence homology search and annotation, we identified a need for interactive web-enabled logos that could efficiently render very long logos, and offer alternate letter height options, improved visualization of per-position gap parameters, and the ability to inspect underlying values. We developed Skylign to meet these needs.

Web-enabled interactive logos

Historically, all logo software has produced static images (e.g. png or vector graphics files). These are the appropriate formats for inclusion in manuscripts and slides, and may be produced with Skylign, but are suboptimal for distribution on the web. For website integration, Skylign implements interactive logos that support navigation to a requested position in the logo, scroll smoothly, and can be zoomed out for a compressed overview of several hundred positions of the logo. Because profile HMMs create positions only for consensus columns, and because a logo stack is defined only for non-empty alignment columns, not all columns in an alignment will be represented by a position in a profile logo; Skylign optionally shows the mapping between each logo position and the corresponding column in the underlying alignment. Skylign logos also support clicking on individual letter stacks to view the underlying values for all letters, as seen in Figure 2.

The data used to produce an interactive logo is stored as a JSON object, which is rendered using HTML5 Canvas and a custom JavaScript module. Adding a Skylign interactive logo to a web page is simple, requiring the addition of a few lines of markup to the page and reference to the Skylign javascript and css files.

Skylign may be used in a variety of ways to create an image or interactive logo. The simplest option is to use the website submission form. Skylign also offers a web service via a RESTful interface, enabling scripted logo creation. Finally, the Skylign package may be downloaded for local installation. Instructions for all of these options are available at http://skylign.org.

Position-specific gap parameters

In addition to representing the letter distribution at each position, Skylign renders position-specific gap parameters. It does this by presenting up to three values for each position k:

1. Occupancy: the probability of observing a letter at position k. If we call this value, occ(k) the probability of observing a gap character (part of a deletion relative to the model) is 1 − occ(k).

2. Insert probability: the probability of observing one or more letters inserted between the letter corresponding to position k and the letter corresponding to position (k + 1).

3. Insert length: the expected length of an insertion following position k, if one is observed. For mathematical convenience, profile HMMs model insertions as having a geometric length distribution with position-specific parameter ϵ and mean length 1/(1 − ϵ).

The later two are only relevant for profile logos, since Skylign creates a logo position for each non-empty column in the alignment when producing an alignment logo.

The tool LogoMat generalized alignment logos to present these gap parameters for profile HMMs. In LogoMat, occupancy is represented by varying the width of the letter stacks (the stack is thinner for positions with lower occupancy). The insertion probability and expected length are represented by placing variable-width two-toned columns between each letter stack, where the width of the darker part of the column corresponds to the insert rate and the width of the lighter part conflates expected length with insert rate. The result is that gap information is encoded by stretching the horizontal plane. As seen in Figure 3A, column width differences are difficult to discern. In Skylign, stack spacing is uniform, and these parameters are instead represented by up to three rows of numerical values placed below the letter stacks of the logo, with a heat map laid over the top of each value to provide a visual aid. See Figure 3B for an example. This approach – pulling gap information into a distinct section below the letter stacks – bears some similarity to the approach used in the SUPERFAMILY database, and simplifies visualization of gap parameters.

Unified framework for profile logos and alignment logos

Skylign can produce a profile logo based on a profile HMM, or an alignment logo based on a sequence alignment, both sharing the same interface. Generating a profile logo is a straightforward matter: a profile HMM stores estimated letter and gap parameters based on the underlying sequence alignment. Skylign simply extracts these values for use in computing stack heights, letter heights, and gap-related values. Alignment logos are more flexible, since Skylign offers four methods for computing estimated distributions from observed frequencies, demonstrated in Figure 4. For all methods, Skylign uses the hmmbuild tool from HMMER 3.1 to compute letter and gap values, with alternate option flags used for each method.

Logo height options

In the case of protein sequences, when observed counts are combined with a strong Dirichlet mixture prior, the posterior letter distribution often contains small but non-negligible probabilities for all 20 letters. This results in an illegible smear of letters at the bottom of the letter stack of the typical logo (Figure 5A). To address this, Skylign offers an alternate method of computing letter heights for a position, in which the only letters shown in each stack are those with above-background probability. Given the column letter distribution and the background distribution, the score of letter a i in that column is its log odds ratio, s i:= log 2(p i /q i ). Letters with above-background probability will have a positive score. Total stack height is computed in the typical fashion (information content), and the height of the stack is subdivided according to the relative probabilities of the positive-scoring letters, as shown in Figure 5B. In the interactive web logo, clicking a column reveals a list of the probabilities of observing each letter at that position (both above- and below-background letters).

Skylign also offers an option to produce a different sort of logo in which the height of each letter is its score, s i. Only positive-scoring letters are included in the stack, as demonstrated in Figure 5C. We find this logo useful, for example, when inspecting per-position scores of an alignment of a sequence to a profile HMM. It is important to emphasize that the height of a score stack does not have any inherent meaning – it is simply the sum of all letter heights. In the interactive web logo, clicking a column reveals a list of scores for all letters of the alphabet, including those with negative scores.

Conclusion

Logos have long been used to visually represent the position-specific patterns of conservation in sequence alignments and profile HMMs. We developed Skylign with the aim of enabling interactive manipulation and inspection of logos, while offering a variety of logo variants for alignments and profiles. The result is a logo tool that supports scrolling, zooming, inspection of underlying values, and mapping between logo positions and alignment columns. Skylign simplifies the representation of gap parameters, offers alternate calculations to determine letter heights, and can overcome sampling bias by down-weighting redundant sequences and by combining observed counts with informed priors.

Skylign’s interactive logos are easily incorporated into a web page, and we have already used them in our HMMER and Dfam webservers, presenting logos for both protein and DNA profile HMMs. We anticipate that Skylign will be used to create logos, either in advance or on the fly, for other sites that present data related to multiple sequence alignments or profile HMMs.

Availability and requirements

Skylign can be accessed as a web server and web service, and may be downloaded for local use at http://skylign.org.

Competing interests

The authors declare that they have no competing interests.

Authors’ contributions

TJW and RDF motivated creation of interactive web logos with improved gap representation. JC developed the code for logo rendering and the web service. TJW implemented routines in HMMER to produce logo parameters and drafted the manuscript. All authors developed code interfacing the web front end with HMMER back end. All authors read and approved the final manuscript.

References 27

  1. 1.

    Krogh A Brown M Mian IS Sjolander K Haussler D Hidden Markov models in computational biologyJ Mol Biol1993 23515011531

    Not in our library10.1006/jmbi.1994.1104

  2. 2.

    Karplus K Barrett C Hughey R Hidden Markov models for detecting remote protein homologiesBioinformatics1998 14846856

    Not in our library10.1093/bioinformatics/14.10.846

  3. 3.
  4. 4.
  5. 5.
  6. 6.

    de Lima Morais DA Fang H Rackham OJL Wilson D Pethica R Chothia C Gough J SUPERFAMILY 1.75 including a domain-centric gene ontology methodNucleic Acids Res2011 39D427D434

    Not in our library10.1093/nar/gkq1130

  7. 7.

    Punta M Coggill PC Eberhardt RY Mistry J Tate J Boursnell C Pang N Forslund K Ceric G Clements J Heger A Holm L Sonnhammer ELL Eddy SR Bateman A Finn RD The Pfam protein families databaseNucleic Acids Res2011 40D290D301

    Not in our library10.1093/nar/gkr1065

  8. 8.

    Hunter S Jones P Mitchell A Apweiler R Attwood TK Bateman A Bernard T Binns D Bork P Burge S de Castro E Coggill P Corbett M Das U Daugherty L Duquenne L Finn RD Fraser M Gough J Haft D Hulo N Kahn D Kelly E Letunic I Lonsdale D Lopez R Madera M Maslen J McAnulla C McDowall J InterPro in 2011: new developments in the family and domain prediction databaseNucleic Acids Res2012 40D306D312

    Not in our library10.1093/nar/gkr948

  9. 9.

    Lees J Yeats C Perkins J Sillitoe I Rentzsch R Dessailly BH Orengo C Gene3D: a domain-based resource for comparative genomics, functional annotation and protein network analysisNucleic Acids Res2012 40D465D471

    Not in our library10.1093/nar/gkr1181

  10. 10.

    Wheeler TJ Clements J Eddy SR Hubley R Jones TA Jurka J Smit AFA Finn RD Dfam: a database of repetitive DNA based on profile hidden Markov modelsNucleic Acids Res2013 41D70D82

    Not in our library10.1093/nar/gks1265

  11. 11.

    Henikoff S Henikoff JG Position-based sequence weightsJ Mol Biol1994 243574578

    Not in our library10.1016/0022-2836(94)90032-9

  12. 12.

    Johnson S Remote Protein Homology Detection Using Hidden Markov Models. PhD thesis2006 St. Louis: Washington University

    Not in our library

  13. 13.

    Brown M Hughey R Krogh A Mian IS Sjolander K Haussler D Using Dirichlet mixture priors to derive hidden Markov models for protein familiesProceedings of the First International Conference on Intelligent Systems for Molecular Biology1993 14755

    Not in our library

  14. 14.

    Sjolander K Karplus K Brown M Hughey R Krogh A Mian IS Haussler D Dirichlet mixtures: a method for improved detection of weak but significant protein sequence homologyBioinformatics1996 12327345

    Not in our library10.1093/bioinformatics/12.4.327

  15. 15.

    MacKay DJC Information theory, inference, and learning algorithms2003 Cambridge: Cambridge Univ Press

    Not in our library

  16. 16.

    Hughey R Krogh A SAM: Sequence alignment and modeling software system1995 Santa Cruz: University of California

    Not in our library

  17. 17.

    Eddy SR Wheeler TJ HMMER User's Guide, version 3.12013 http://hmmer.janelia.org/

    Not in our library

  18. 18.

    Schneider TD Stormo GD Gold L Ehrenfeucht A Information content of binding sites on nucleotide sequencesJ Mol Biol1986 188415431

    Not in our library10.1016/0022-2836(86)90165-8

  19. 19.

    Schneider TD Stephens RM Sequence logos: a new way to display consensus sequencesNucleic Acids Res1990 1860976100

    Not in our library10.1093/nar/18.20.6097

  20. 20.

    Schuster-Böckler B Schultz J Rahmann S HMM logos for visualization of protein familiesBMC Bioinformatics2004 57

    Not in our library10.1186/1471-2105-5-7

  21. 21.

    Kullback S Leibler RA On information and sufficiencyAnn Math Stat1951 227986

    Not in our library10.1214/aoms/1177729694

  22. 22.

    Gorodkin J Heyer LJ Brunak S Stormo GD Displaying the information contents of structural RNA alignments: the structure logosComput Applic Biosci1997 13583586

    Not in our library10.1093/bioinformatics/13.6.583

  23. 23.

    Crooks GE Hon G Chandonia JM Brenner SE WebLogo: a sequence logo generatorGenome Res2004 1411881190

    Not in our library10.1101/gr.849004

  24. 24.

    Thomsen MCF Nielsen M Seq2Logo: a method for construction and visualization of amino acid binding motifs and sequence profiles including sequence weighting, pseudo counts and two-sided representation of amino acid enrichment and depletionNucleic Acids Res2012 40W281W287

    Not in our library10.1093/nar/gks469

  25. 25.

    Fielding RT Taylor RN Principled design of the modern Web architectureACM Transactions on Internet Technology2002 2115150

    Not in our library10.1145/514183.514185

  26. 26.

    Gardner PP Daub J Tate J Moore BL Osuch IH Griffiths-Jones S Finn RD Nawrocki EP Kolbe DL Eddy SR Bateman A Rfam: Wikipedia, clans and the “decimal” releaseNucleic Acids Res2010 39D141D145

    Not in our library10.1093/nar/gkq1129

  27. 27.

    Finn RD Clements J Eddy SR HMMER web server: interactive sequence similarity searchingNucleic Acids Res2011 39W29W37

    Not in our library10.1093/nar/gkr367

Cited by papers we hold 7

Reads

Read by people on this page

None yet.

Checked or read by AI through naulon

None yet.

A person counts once a day per paper. We keep no cookie and no address: a reader is a hash that changes every day. Any month under five reads shows no number.

Are you an author?

Is this your paper?

Claim it to add your note and be paid when agents cite it. Free.