コード例 #1
0
ファイル: 20080225b.py プロジェクト: BIGtigr/xgcode
def get_form():
    """
    @return: the body of a form
    """
    # define the default rate matrix
    dictionary_rate_matrix = RateMatrix.get_sample_codon_rate_matrix()
    labels = list(sorted(set(a for a, b in dictionary_rate_matrix)))
    R = MatrixUtil.dict_to_row_major(dictionary_rate_matrix, labels, labels)
    R = np.array(R)
    form_objects = [
        Form.Matrix('matrix', 'rate matrix', R, MatrixUtil.assert_rate_matrix)
    ]
    return form_objects
コード例 #2
0
ファイル: 20080225e.py プロジェクト: argriffing/xgcode
def get_form():
    """
    @return: the body of a form
    """
    # define the default rate matrix
    dictionary_rate_matrix = RateMatrix.get_sample_codon_rate_matrix()
    labels = list(sorted(set(a for a, b in dictionary_rate_matrix)))
    R = MatrixUtil.dict_to_row_major(dictionary_rate_matrix, labels, labels)
    R = np.array(R)
    form_objects = [
            Form.Matrix('matrix', 'rate matrix',
                R, MatrixUtil.assert_rate_matrix)]
    return form_objects
コード例 #3
0
ファイル: 20080223a.py プロジェクト: BIGtigr/xgcode
def get_form():
    """
    @return: the body of a form
    """
    # define the default rate matrix
    dictionary_rate_matrix = RateMatrix.get_sample_codon_rate_matrix()
    labels = Codon.g_sorted_non_stop_codons
    R = MatrixUtil.dict_to_row_major(dictionary_rate_matrix, labels, labels)
    # define the form objects
    form_objects = [
        Form.Matrix('matrix', 'codon rate matrix', R,
                    MatrixUtil.assert_rate_matrix),
        Form.Integer('maxcategories', 'maximum number of categories', 5, low=2)
    ]
    return form_objects
コード例 #4
0
ファイル: 20080223a.py プロジェクト: argriffing/xgcode
def get_form():
    """
    @return: the body of a form
    """
    # define the default rate matrix
    dictionary_rate_matrix = RateMatrix.get_sample_codon_rate_matrix()
    labels = Codon.g_sorted_non_stop_codons
    R = MatrixUtil.dict_to_row_major(dictionary_rate_matrix, labels, labels)
    # define the form objects
    form_objects = [
            Form.Matrix('matrix', 'codon rate matrix',
                R, MatrixUtil.assert_rate_matrix),
            Form.Integer('maxcategories', 'maximum number of categories',
                5, low=2)]
    return form_objects