ConductScience Sequences
Contents

User guide · Search methods

Exact and pattern search

Exact text and Pattern cover every stored sequence, so their counts are complete.

Exact text and Pattern cover every stored sequence, so their counts are complete. They compare DNA with DNA or protein with protein. A DNA search covers both strands unless you clear Search both strands. In a set with a DNA fragment index, an Exact text search of DNA queries of 15 to 50 bases, all A, C, G or T, looks them up there in place of reading every stored sequence, with the same results, unless you turn on stored codes.

QueryStored sequence
Exact text and Pattern: the query, or a sequence the pattern allows, appears unchanged in a stored sequence.

To try them, choose Use demo data. With Exact text it fills SEQ ID NO: 1 of US12788009B2, which its claim 1 recites (us12788009b2-seq1.fasta), or for DNA / RNA the probe of US12788762B2 (us12788762b2-probe.fasta). With Pattern, the button under Pattern fills claim 1 of US12788009B2 as a PROSITE pattern (us12788009b2-pattern.txt) or as a regular expression (us12788009b2-pattern-regex.txt), and for DNA / RNA a primer of US12788762B2 with IUPAC codes (us12788762b2-primer-pattern.txt).

Pattern syntax says how you write a pattern: PROSITE, the first choice, or Regular expression. Sequences never guesses, since [AG] and parentheses mean different things in the two.

A PROSITE pattern is parts joined by hyphens:

PartMeans
ACGTThese letters, in this order
[AG]A or G
{AG}Any letter but A or G
xAny letter
x(2,6)2 to 6 of any letter. A repeat goes on one letter or one bracket, as in A(3) or [AG](2,4)
< and >Before the first part, the start of the stored sequence; after the last, its end

For example, AAGCTT-x(2,6)-GGATCC finds a HindIII site, 2 to 6 letters, then a BamHI site.

A regular expression takes these parts:

PartMeans
ACGTThese letters, in this order
[AG] and [^AG]A or G, and any letter but A or G
.Any letter
{3}, {2,6} and {2,}3, 2 to 6, or 2 to 1,000 of the letter, bracket or dot before it
?, + and *0 or 1, 1 to 1,000, and 0 to 1,000 of the letter, bracket or dot before it
^ and $The start and the end of the stored sequence

Parentheses with a bar give choices: (GGATCC|AAGCTT) finds a BamHI or a HindIII site. An expression takes up to 8 choices, and two sets of choices in a row multiply, so (A|C)(G|T) makes 4. AAGCTT.{2,6}GGATCC finds what AAGCTT-x(2,6)-GGATCC finds. Sequences turns each choice into a PROSITE pattern and searches them together, so a place that two choices fit is listed once, and the search record keeps the expression as you typed it and its PROSITE form. A regular expression cannot hold a backreference such as \1, a lookahead or lookbehind such as (?=, or a repeat on a group such as (AG){3}, which you can write out as AGAGAG. The message names the part it cannot take.

In DNA, IUPAC codes such as R and N stand for their bases. A pattern takes at most 100 parts, 4 ranges such as x(2,6) or {2,6}, repeat counts up to 1,000, and 20,000 characters. In a regular expression ?, + and * are ranges too, a run of letters is one part, and each choice keeps within these limits.

Unless you turn on stored codes, a letter in a stored sequence matches only that letter, so an N in stored DNA, or an X in a stored protein, is not a wildcard here. An alignment counts it apart from a mismatch (see Results). Each row is one sequence on one strand. Occurrences counts every place the text or pattern fits, and First positions lists up to 20 of them, counted from the start of the stored sequence. The list stops at 1,000,000 rows, and the totals still count every match. If a search's rows and their alignments pass 8 GiB, or another size the server sets, the search fails with "The result exceeded its size limit. Use fewer or longer queries." The scan reads the set in parts, one for each thread, and each part stops keeping rows once its rows reach an equal share of that size, so the list can also end before 1,000,000 rows. The totals still count every match.

A DNA query with IUPAC codes reads differently by method. Pattern reads R as A or G, and each other code as the bases it stands for. Exact text matches R only to R, and BLAST, alone or in Automatic, counts R against A or G as a mismatch. So when the query box holds DNA with codes and the method is neither Pattern nor Within k changes, which reads codes as Pattern does, a note under the box offers Search as a pattern. It puts the query in Pattern as PROSITE letters, or up to 8 queries as one regular expression, and leaves the query box as it was. Unless you turn on stored codes, a pattern takes a code written in a stored sequence as a letter of its own, not as the bases it stands for, so the two searches find different things. In our check of the demo primers of US12788762B2 against two coronavirus reference genomes, Pattern found each site the codes allow and Exact text only the patent's own listing. BLAST found both, but read SEQ ID NO: 1 at 92.3% identity both where its codes fit and where one letter differs.

Stored IUPAC codes

A sequence listing can write a place that holds one of several bases or amino acids as an IUPAC code, such as R for A or G, N for any base, or X for any amino acid. Check Let stored IUPAC codes match the letters they stand for, under Exact text or Pattern, and a code in a stored sequence matches each letter it stands for: R matches A or G, Y matches C or T, N matches any base, and so on for each code. In a protein, B matches D or N, Z matches E or Q, J matches I or L, and X matches any amino acid. Most codes in one match, 3 to start, limits how many codes one match may hold to 1, 2, 3, 5 or 10, so that a run of N does not match every search. A code in an Exact text query still matches only the same code, and that match is not counted.

Whatever a search finds with the box clear, it finds with the box checked. A place counts when the search fits it with no more codes than Most codes in one match allows. Where a sequence has more than one such place, or a pattern fits one place in more than one way, the row shows the match with the fewest codes, and Occurrences and First positions count every place. The Stored codes column, shown for such a search, gives the number of codes in the row's match. The pane names each one as the alignment shows it, with its position in the stored sequence and, for Exact text, the letter of your query it stands for, such as "1 code: R at 7 for A". An Exact text row counts each code as a letter that is not identical, so a match of 8 letters with one code reads Identity 87.5% and leaves Query Match empty, while Identity, X as a match still counts a stored N or X as identical. In a pattern, x and . take a code as they take any letter, so it is not counted. The search record says the box was checked and gives the limit, and the CSV gives the number of codes in stored_codes.

Guide version 1.91.0 · For Sequences 0.155.0