string_utils.h File Reference
Utilities » Parsing, Converting, and Comparing - Functions to Manipulate Sequence and Structure Strings

General utility- and helper-functions for RNA sequence and structure strings used throughout the ViennaRNA Package. More...

Include dependency graph for string_utils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Macros

#define | XSTR(s) STR(s)
| Stringify a macro after expansion.
#define | STR(s) #s
| Stringify a macro argument.
#define | FILENAME_MAX_LENGTH 80
| Maximum length of filenames that are generated by our programs. More...
#define | FILENAME_ID_LENGTH 42
| Maximum length of id taken from fasta header for filename generation. More...

## Functions

char * | vrna_random_string (int l, const char symbols[])
| Create a random string using characters from a specified symbol set. More...
int | vrna_hamming_distance (const char *s1, const char *s2)
| Calculate hamming distance between two sequences. More...
int | vrna_hamming_distance_bound (const char *s1, const char *s2, int n)
| Calculate hamming distance between two sequences up to a specified length. More...
void | vrna_seq_toRNA (char *sequence)
| Convert an input sequence (possibly containing DNA alphabet characters) to RNA alphabet. More...
void | vrna_seq_toupper (char *sequence)
| Convert an input sequence to uppercase. More...
char * | vrna_cut_point_insert (const char *string, int cp)
| Add a separating '&' character into a string according to cut-point position. More...
char * | vrna_cut_point_remove (const char *string, int *cp)
| Remove a separating '&' character from a string. More...
void | str_uppercase (char *sequence)
| Convert an input sequence to uppercase. More...
void | str_DNA2RNA (char *sequence)
| Convert a DNA input sequence to RNA alphabet. More...
char * | random_string (int l, const char symbols[])
| Create a random string using characters from a specified symbol set. More...
int | hamming (const char *s1, const char *s2)
| Calculate hamming distance between two sequences. More...
int | hamming_bound (const char *s1, const char *s2, int n)
| Calculate hamming distance between two sequences up to a specified length. More...

## Detailed Description

General utility- and helper-functions for RNA sequence and structure strings used throughout the ViennaRNA Package.

## Function Documentation

void str_uppercase | ( | char * | sequence | ) |

Convert an input sequence to uppercase.

Deprecated:
  Use vrna_seq_toupper() instead!

void str_DNA2RNA | ( | char * | sequence | ) |

Convert a DNA input sequence to RNA alphabet.

Deprecated:
  Use vrna_seq_toRNA() instead!

char* random_string | ( | int | l,
|  | const char | symbols[]
| ) |  |

Create a random string using characters from a specified symbol set.

Deprecated:
  Use vrna_random_string() instead!

int hamming | ( | const char * | s1,
|  | const char * | s2
| ) |  |

Calculate hamming distance between two sequences.

Deprecated:
  Use vrna_hamming_distance() instead!

int hamming_bound | ( | const char * | s1,
|  | const char * | s2,
|  | int | n
| ) |  |

Calculate hamming distance between two sequences up to a specified length.

Deprecated:
  Use vrna_hamming_distance_bound() instead!