Main Content

atomiccomp

Calculate atomic composition of protein

Syntax

NumberAtoms = atomiccomp(SeqAA)

Arguments

SeqAA

Amino acid sequence. Enter a character vector or vector of integers from the table Mapping Amino Acid Letter Codes to Integers. You can also enter a structure with the field Sequence.

Description

NumberAtoms = atomiccomp(SeqAA) counts the type and number of atoms in an amino acid sequence (SeqAA) and returns the counts in a 1-by-1 structure (NumberAtoms) with fields C, H, N, O, and S.

Examples

collapse all

Retrieve an amino acid sequence from the NCBI GenPept database.

rhodopsin = getgenpept('NP_000530')
rhodopsin = 

  struct with fields:

                LocusName: 'NP_000530'
      LocusSequenceLength: '348'
     LocusNumberofStrands: ''
            LocusTopology: 'linear'
        LocusMoleculeType: ''
     LocusGenBankDivision: 'PRI'
    LocusModificationDate: '07-AUG-2015'
               Definition: 'rhodopsin [Homo sapiens].'
                Accession: 'NP_000530'
                  Version: 'NP_000530.1'
                       GI: '4506527'
                  Project: []
                   DBLink: ' DBSOURCE    REFSEQ: accession NM_000539.3'
                 Keywords: 'RefSeq.'
                  Segment: []
                   Source: 'Homo sapiens  human '
           SourceOrganism: [4×65 char]
                Reference: {1×18 cell}
                  Comment: [26×67 char]
                 Features: [219×74 char]
                      CDS: [1×1 struct]
                 Sequence: 'mngtegpnfyvpfsnatgvvrspfeypqyylaepwqfsmlaaymfl...'
                SearchURL: 'http://www.ncbi.nlm.nih.gov/entrez/viewer.fcgi...'
              RetrieveURL: 'http://eutils.ncbi.nlm.nih.gov/entrez/eutils/e...'

Count the atoms in the sequence.

rhodopsinAC = atomiccomp(rhodopsin)
rhodopsinAC = 

  struct with fields:

    C: 1814
    H: 2725
    N: 423
    O: 477
    S: 25

Retrieve the number of carbon atoms.

rhodopsinAC.C
ans =

        1814

Introduced before R2006a