Class ProfileHMM

    • Method Detail

      • columns

        public int columns()
        Retrieve the number of columns in the model.
        Returns:
        the number of columns
      • getMatch

        public EmissionState getMatch​(int indx)
                               throws java.lang.IndexOutOfBoundsException
        Retrieve the match state at column indx.

        The first match state is at index 1, and the last match state is at column columns(). The states at index 0 and columns()+1 are both the magical state. This is so that the whole model backbone can be addressed without writing lots of special-case code.

        Parameters:
        indx - the index of the column to retrieve the match state for
        Returns:
        the match state for column indx
        Throws:
        java.lang.IndexOutOfBoundsException - if indx is negative or above columns()+1
      • getInsert

        public EmissionState getInsert​(int indx)
                                throws java.lang.IndexOutOfBoundsException
        Retrieves the insert state at column indx.

        Insert_0 is the insert that is accessible directly from the magical state. Insert_1..columns() are 'above' each propper match state. There is no insert state above the magical state at the end of the model, as insert_columns already models trailing inserts.

        Parameters:
        indx - the index of the column to retrieve the insert state for
        Returns:
        the insert state for column indx
        Throws:
        java.lang.IndexOutOfBoundsException - if indx is negative or above columns()
      • getDelete

        public DotState getDelete​(int indx)
                           throws java.lang.IndexOutOfBoundsException
        Retrieves the delete state for column indx.

        Delete states are 'above' the match state that they delete. There is no delete state for the magical state at either the beginning or end of the model, so the delete state indx can range within (1..columns()).

        Parameters:
        indx - the index of the column to retrieve the insert state for
        Returns:
        the insert state for column indx
        Throws:
        java.lang.IndexOutOfBoundsException - if indx is negative or above columns()