Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Generate the stave diagram corresponding to a nucleotide sequence
ResourceFunction["NucleotideStaveDiagram"][bioseq] visualizes the "DNA" or "RNA" BioSequence bioseq as a stave diagram. |
"MaxColumns" | Automatic | maximum number of columns on a stave before moving to a new one |
PlotStyle | Automatic | graphics directives to determine styles of markers |
"ShowLabels" | True | whether to show labels for the nucleotides |
"StaveStyle" | Automatic | style specifications for the staves |
"WildcardStyle" | Automatic | graphics directives to determine styles of markers corresponding to degenerate letters |
Stave diagram for a DNA sequence:
In[1]:= |
Out[1]= |
Stave diagram for an RNA sequence:
In[2]:= |
Out[2]= |
Stave diagram for a gene:
In[3]:= |
Out[3]= |
Stave diagram for a sequence containing degenerate letters:
In[4]:= |
Out[4]= |
NucleotideStaveDiagram can be used on strings and will infer the sequence type from the letters:
In[5]:= |
Out[5]= |
The setting "MaxColumns"→Automatic corresponds to a cutoff of 120 columns. Use a smaller number of columns:
In[6]:= |
Out[6]= |
Use different style directives for markers corresponding to non-degenerate letters:
In[7]:= |
Out[7]= |
Show the stave diagram with and without the nucleotide labels:
In[8]:= |
Out[8]= |
Specify the style to use for the staves:
In[9]:= |
Out[9]= |
Use different style directives for markers corresponding to degenerate letters:
In[10]:= |
Out[10]= |
The stave diagram of a sequence and its complement are mirror reflections of each other:
In[11]:= |
Out[11]= |
Palindromic sequences have centrally symmetric stave diagrams:
In[12]:= |
Out[12]= |
This work is licensed under a Creative Commons Attribution 4.0 International License