Represents the LibraryOptions
section of mascot.dat
.
More...
#include <ms_libraryoptions.hpp>
Public Member Functions | |
ms_libraryoptions () | |
Default constructor. | |
ms_libraryoptions (const ms_libraryoptions &src) | |
Copying constructor. | |
~ms_libraryoptions () | |
Destructor. | |
void | copyFrom (const ms_libraryoptions *right) |
Can be used to copy content from another instance. | |
void | defaultValues () |
Initializes the instance. | |
void | dropSpectralLibrary (const char *spectralLibraryName) |
Remove all references to the specified spectral library. | |
std::string | getLibraryName (const int num) const |
Return the name of the library. | |
int | getNumberOfLibraries () const |
Return the number of libraries. | |
std::string | getPreceedingComments () const |
Returns any comments preceeding the section. | |
std::string | getReferenceFasta (const char *spectralLibraryName) const |
Returns the name of the Fasta database used as a reference for accessions for the spectral library. | |
std::string | getReferenceFastaTaxonomyTitle (const char *spectralLibraryName) const |
Returns the title of the taxonomy to use for the reference database. | |
double | getToleranceInDa (const char *spectralLibraryName) const |
Returns the tolerance of the data in spectral library. | |
double | getToleranceInPPM (const char *spectralLibraryName) const |
Returns the tolerance of the data in spectral library. | |
bool | isSectionAvailable () const |
Check whether the section has been actually read from the file. | |
ms_libraryoptions & | operator= (const ms_libraryoptions &right) |
Assignment operator for C++ client applications. | |
void | setPreceedingComments (const std::string &comments) |
Sets any comments preceeding the section. | |
void | setReferenceFasta (const char *spectralLibraryName, const char *fastaDatabaseName, const char *taxonomyTitle) |
Sets the name of the Fasta database used as a reference for accessions for the spectral library. | |
void | setSectionAvailable (const bool value) |
Changes availability of the section, i.e. whether it should be saved in a file. | |
void | setToleranceInDa (const char *spectralLibraryName, double tolerance) |
Sets the tolerance of the data in spectral library. | |
void | setToleranceInPPM (const char *spectralLibraryName, double tolerance) |
Sets the tolerance of the data in spectral library. |
Represents the LibraryOptions
section of mascot.dat
.
See : ms_datfile::getLibraryOptions and ms_datfile::setLibraryOptions
Also get yourselves acquainted with the base class ms_customproperty. It facilitates the following tasks:
More functionality is described in the documentation for ms_customproperty.
Default constructor.
Create an object with no options
ms_libraryoptions | ( | const ms_libraryoptions & | src ) |
Copying constructor.
C++ only. Use copyFrom from other languages.
src | is the source options to copy into the new object |
~ms_libraryoptions | ( | ) |
Destructor.
Frees any memory
void copyFrom | ( | const ms_libraryoptions * | right ) |
Can be used to copy content from another instance.
Copy all the parameter for the libraries from right into the object
right | is the source library options |
void defaultValues | ( | ) |
Initializes the instance.
Remove details for all the libraries
Reimplemented from ms_customproperty.
void dropSpectralLibrary | ( | const char * | spectralLibraryName ) |
Remove all references to the specified spectral library.
spectralLibraryName | is the (short) name of the library |
std::string getLibraryName | ( | const int | num ) | const |
Return the name of the library.
num | must be in the range 0 to getNumberOfLibraries() -1 |
int getNumberOfLibraries | ( | ) | const |
Return the number of libraries.
std::string getPreceedingComments | ( | ) | const [inherited] |
Returns any comments preceeding the section.
Sections in the mascot.dat file may have comments preceeding them. In most cases, these comments need to stay 'attached' to the section.
Multiple line comments are supported by having a single string with newline characters
std::string getReferenceFasta | ( | const char * | spectralLibraryName ) | const |
Returns the name of the Fasta database used as a reference for accessions for the spectral library.
A Spectral library is essentially a peptide library and will often not contain meaningful accessions. To get useful protein grouping in Mascot reports, it is recommended that users specify a 'reference' database. When a reference database is used, Mascot tries to find the peptide sequence from the library in the reference fasta, and if it is found then it adds the accession for that protein sequence to the search results.
spectralLibraryName | is the (short) name of the library |
std::string getReferenceFastaTaxonomyTitle | ( | const char * | spectralLibraryName ) | const |
Returns the title of the taxonomy to use for the reference database.
The reference database may contain protein accessions from multiple taxa. If a suitable taxonomy index is configured, you can define the taxon to use for reference accessions. The returned value is the title string of an entry in the taxonomy configuration file (typically mascot/config/taxonomy).
spectralLibraryName | is the (short) name of the library |
double getToleranceInDa | ( | const char * | spectralLibraryName ) | const |
Returns the tolerance of the data in spectral library.
A spectral library is created using an instrument with a known tolerance and this tolerance is specified by the user when they enable the use of the library in Mascot. When the library is searched, the tolerance used is the square root of the sum of the squares of the data being searched and this value.
The tolerance of the library is specified in Da and ppm since the user may choose either units when they submit a search.
See also, getToleranceInPPM(), setToleranceInPPM() and setToleranceInDa()
If spectralLibraryName does not exist, returns the default (0.6 Da)
spectralLibraryName | is the (short) name of the library |
double getToleranceInPPM | ( | const char * | spectralLibraryName ) | const |
Returns the tolerance of the data in spectral library.
A spectral library is created using an instrument with a known tolerance and this tolerance is specified by the user when they enable the use of the library in Mascot. When the library is searched, the tolerance used is the square root of the sum of the squares of the data being searched and this value.
The tolerance of the library is specified in Da and ppm since the user may choose either units when they submit a search.
See also, setToleranceInPPM(), getToleranceInDa() and setToleranceInDa()
If spectralLibraryName does not exist, returns the default (500ppm)
spectralLibraryName | is the (short) name of the library |
bool isSectionAvailable | ( | ) | const |
Check whether the section has been actually read from the file.
By default the LibraryOptions
section is unavailable until it has been set to a different state.
The section does not have to exist in the mascot.dat file
ms_libraryoptions & operator= | ( | const ms_libraryoptions & | right ) |
Assignment operator for C++ client applications.
C++ only
right | is the source library options |
void setPreceedingComments | ( | const std::string & | comments ) | [inherited] |
Sets any comments preceeding the section.
Sections in the mascot.dat file may have comments preceeding them. In most cases, these comments need to stay 'attached' to the section.
Multiple line comments are supported by having a single string with newline characters
comments | any comments preceeding the section |
void setReferenceFasta | ( | const char * | spectralLibraryName, |
const char * | fastaDatabaseName, | ||
const char * | taxonomyTitle | ||
) |
Sets the name of the Fasta database used as a reference for accessions for the spectral library.
A Spectral library is essentially a peptide library and will often not contain meaningful accessions. To get useful protein grouping in Mascot reports, it is recommended that users specify a 'reference' database. When a reference database is used, Mascot tries to find the peptide sequence from the library in the reference fasta. If it is found, Mascot adds the accession for that protein sequence to the search results.
The reference database may contain protein accessions from multiple taxa. To restrict accesions to a particular taxon, give its title as the third argument. Titles typically come from the taxonomy configuration file (mascot/config/taxonomy). If left empty, there is no restriction.
spectralLibraryName | is the (short) name of the library |
fastaDatabaseName | is the (short) name of the reference database |
taxonomyTitle | is the title of the taxon to use, or the empty string. |
void setSectionAvailable | ( | const bool | value ) |
Changes availability of the section, i.e. whether it should be saved in a file.
The section does not have to exist in the mascot.dat file
value | set to true if the section exists |
void setToleranceInDa | ( | const char * | spectralLibraryName, |
double | tolerance | ||
) |
Sets the tolerance of the data in spectral library.
A spectral library is created using an instrument with a known tolerance and this tolerance is specified by the user when they enable the use of the library in Mascot. When the library is searched, the tolerance used is the square root of the sum of the squares of the data being searched and this value.
The tolerance of the library is specified in Da and ppm since the user may choose either units when they submit a search.
See also, getToleranceInPPM(), setToleranceInPPM() and getToleranceInDa()
If spectralLibraryName does not exist, returns the default (500ppm)
spectralLibraryName | is the (short) name of the library |
tolerance | is the new tolerance for spectralLibraryName |
void setToleranceInPPM | ( | const char * | spectralLibraryName, |
double | tolerance | ||
) |
Sets the tolerance of the data in spectral library.
A spectral library is created using an instrument with a known tolerance and this tolerance is specified by the user when they enable the use of the library in Mascot. When the library is searched, the tolerance used is the square root of the sum of the squares of the data being searched and this value.
The tolerance of the library is specified in Da and ppm since the user may choose either units when they submit a search.
See also, getToleranceInPPM(), getToleranceInDa() and setToleranceInDa()
If spectralLibraryName does not exist, this adds a new entry for the library and sets a default value for other parameters for the library
spectralLibraryName | is the (short) name of the library |
tolerance | is the new tolerance for spectralLibraryName |
Copyright © 2022 Matrix Science Ltd. All Rights Reserved. Generated on Thu Mar 31 2022 01:12:33 |