FreeSASA  2.0.1
Open source SASA calculations
View on GitHub
Typedefs | Enumerations | Functions | Variables
Classifier

Interface for classifying atoms as polar/apolar and determining their radius based on atom name and residue name. More...

Typedefs

typedef struct freesasa_classifier freesasa_classifier
 Struct that can be used to determine classes (polar/apolar) and radii of atoms. More...
 

Enumerations

enum  freesasa_atom_class { FREESASA_ATOM_APOLAR =0, FREESASA_ATOM_POLAR =1, FREESASA_ATOM_UNKNOWN =2 }
 Atoms can be of the classes Apolar, Polar or Unknown.
 

Functions

freesasa_classifierfreesasa_classifier_from_file (FILE *file)
 Generate a classifier from a config-file. More...
 
void freesasa_classifier_free (freesasa_classifier *classifier)
 Frees a classifier object. More...
 
double freesasa_classifier_radius (const freesasa_classifier *classifier, const char *res_name, const char *atom_name)
 Use a classifier to determine the radius of a given atom. More...
 
freesasa_atom_class freesasa_classifier_class (const freesasa_classifier *classifier, const char *res_name, const char *atom_name)
 Use a classifier to determine the class of a given atom. More...
 
const char * freesasa_classifier_class2str (freesasa_atom_class atom_class)
 Names for freesasa_atom_class. More...
 
const char * freesasa_classifier_name (const freesasa_classifier *classifier)
 The name of a classifier. More...
 

Variables

const freesasa_classifier freesasa_protor_classifier
 Classifier using ProtOr radii and classes.
 
const freesasa_classifier freesasa_naccess_classifier
 Classifier using NACCESS radii and classes.
 
const freesasa_classifier freesasa_oons_classifier
 Classifier using OONS radii and classes.
 

Detailed Description

Interface for classifying atoms as polar/apolar and determining their radius based on atom name and residue name.

Typedef Documentation

Struct that can be used to determine classes (polar/apolar) and radii of atoms.

Initiated from freesasa_classifier_from_file(). The classifiers freesasa_default_classifier, freesasa_protor_classifier, freesasa_naccess_classifier and freesasa_classifier are const classifiers that can be used directly.

Definition at line 266 of file freesasa.h.

Function Documentation

freesasa_classifier* freesasa_classifier_from_file ( FILE *  file)

Generate a classifier from a config-file.

Input file format described in Classifier configuration files

Return value is dynamically allocated, should be freed with freesasa_classifier_free().

Parameters
fileFile containing configuration
Returns
The generated classifier. NULL if there were problems parsing or reading the file or memory allocation problem.
See also
Classifier configuration files
void freesasa_classifier_free ( freesasa_classifier classifier)

Frees a classifier object.

Parameters
classifierThe classifier.
double freesasa_classifier_radius ( const freesasa_classifier classifier,
const char *  res_name,
const char *  atom_name 
)

Use a classifier to determine the radius of a given atom.

Parameters
classifierThe classifier.
res_nameThe residue name (ALA/VAL/U/C/...)
atom_nameThe atom name (CA/N/CB/...)
Returns
The radius, negative if atom unknown.
freesasa_atom_class freesasa_classifier_class ( const freesasa_classifier classifier,
const char *  res_name,
const char *  atom_name 
)

Use a classifier to determine the class of a given atom.

Parameters
classifierThe classifier.
res_nameThe residue name (ALA/VAL/U/C/...)
atom_nameThe atom name (CA/N/CB/...)
Returns
The class.
const char* freesasa_classifier_class2str ( freesasa_atom_class  atom_class)

Names for freesasa_atom_class.

Parameters
atom_classThe class.
Returns
Name of class.
const char* freesasa_classifier_name ( const freesasa_classifier classifier)

The name of a classifier.

Parameters
classifierThe classifier.
Returns
The name of the classifier.