Ejemplo n.º 1
0
### Simulations done over all peptides

from run_mc import *

nb_cycles = 1
beta = 1.0
nb_runs = 1000

test_peptide = PDZ_Data.peptides[11]
calc_energy_ground()

run_mc(nb_runs, test_peptide, beta, nb_cycles=nb_cycles, plot=True, verbose=False)

plot_freq_matrix(test_peptide)

print compute_entropy_sequence(test_peptide)

mi = compute_mutual_information(test_peptide)

plt.imshow(mi, interpolation="nearest", cmap=plt.cm.Blues, aspect="auto")
plt.colorbar()
plt.show()
Ejemplo n.º 2
0
### Testing whether code functions well or not

from all_data import *
from run_mc import *

bn = 7.0
PDZ_Data.divide_peps()
calc_energy_ground()
test_peptide = PDZ_Data.peptide_dist[bn][0]
print test_peptide.name
print test_peptide.sequence_bis
print test_peptide.energy_ground

for peptide in PDZ_Data.peptide_dist[bn]:
    print "{} {}".format(peptide.name, peptide.sequence_bis)

run_mc(100, test_peptide, beta = 1.01, nb_cycles = 5, plot = True)

print compute_entropy_sequence(test_peptide)