from modeller import *

env = environ()
aln = alignment(env)
for (pdb, chain) in (('1a0j', 'A'), ('2a31', 'A'), ('1a5i', 'A'),
                     ('4a5t', 'S'), ('1a7s', 'A'), ('5abw', 'A')):
    m = model(env, file=pdb, model_segment=('FIRST:'+chain, 'LAST:'+chain))
    aln.append_model(m, atom_files=pdb, align_codes=pdb+chain)
aln.malign()
aln.malign3d()
aln.compare_structures()
aln.id_table(matrix_file='family.mat')
env.dendrogram(matrix_file='family.mat', cluster_cut=-1.0)

'''
(('1a0j', 'A'), ('2a31', 'A'), ('1a5i', 'A'),
                     ('4a5t', 'S'), ('1a7s', 'A'), ('5abw', 'A'))
'''
