diff --git a/Makefile b/Makefile index 53a9b18..2da9c93 100644 --- a/Makefile +++ b/Makefile @@ -19,10 +19,10 @@ tests: python3 testsuite/grxmc_ideal_tests.py python3 testsuite/peptide_tests.py python3 testsuite/weak_polyelectrolyte_dialysis_test.py + python3 testsuite/globular_protein_tests.py sample: python3 sample_scripts/peptide_simulation_example.py - visual: python3 handy_scripts/vmd-traj.py vmd -e visualization.tcl diff --git a/lib/create_cg_from_pdb.py b/lib/create_cg_from_pdb.py index 11f0aef..f21f35d 100644 --- a/lib/create_cg_from_pdb.py +++ b/lib/create_cg_from_pdb.py @@ -308,14 +308,17 @@ def create_sidechain_beads (pdb_df) : x_coord_r = pdb_df['x_pos'] y_coord_r = pdb_df['y_pos'] z_coord_r = pdb_df['z_pos'] + + pdb_df['radius_mean'] = pdb_df.groupby(['residue_name'])['radius_r'].transform (np.mean).round(4) atom_number_pdb_r = pd.Series(pdb_df.residue_number) resname_r = pd.Series(pdb_df.residue_name) resname_one_letter_r= pd.Series (pdb_df.resname_one_letter) resid_r = pd.Series(pdb_df.residue_number) - radius_r = pd.Series(pdb_df['radius_r']) + radius_r = pd.Series(pdb_df['radius_mean']) chain_r = pd.Series(pdb_df.chain_id) + residues_bead = {'atom_numbers_r': atom_number_pdb_r,\ 'x_coord_r':x_coord_r,'y_coord_r':y_coord_r,'z_coord_r':z_coord_r, \ 'resname_r':resname_r,'resname_one_letter_r':resname_one_letter_r , 'radius_r':radius_r, 'chain_r': chain_r, 'resid_r': resid_r} @@ -507,7 +510,7 @@ def create_output_coarse_grain_model_as_vtf_file (coarse_grain,beads_bond, iden parser = argparse.ArgumentParser(description='Creates a coarse-grained model from a protein structure given in PDB format') parser.add_argument('--filename', dest='filename', help='\nPath to the PDB file\n') parser.add_argument('--download_pdb', dest='pdb_code', help='Downloads the corresponding PDB from RCSB and coarse-grains it') - parser.add_argument('--model', dest='model', default='2bead', type=str , help='\nCoarse-grained model to be used\n') + parser.add_argument('--model', dest='model', default='2beadAA', type=str , help='\nCoarse-grained model to be used\n') parser.add_argument('--chain_id', type=str , help='\nSpecific chaid_id to coarse-grain\n') parser.add_argument('--verbose', dest='verbose', action='store_true') parser.add_argument('--no-verbose', dest='verbose', action='store_false') diff --git a/maintainer/standarize_data.py b/maintainer/standarize_data.py index fcec0d1..c4460d9 100644 --- a/maintainer/standarize_data.py +++ b/maintainer/standarize_data.py @@ -11,7 +11,10 @@ supported_filenames=["data_landsgesell.csv", "Glu-HisMSDE.csv", "Lys-AspMSDE.csv", - "histatin5_SoftMatter.txt"] + "histatin5_SoftMatter.txt", + "1beb-10mM-torres.dat", + "1f6s-10mM-torres.dat"] + parser = argparse.ArgumentParser(description='Script to standarize the data from various authors') parser.add_argument('--src_filename', @@ -27,7 +30,9 @@ output_filenames={"data_landsgesell.csv": "Landsgesell2020a.csv", "Lys-AspMSDE.csv": "Lunkad2021a.csv", "Glu-HisMSDE.csv": "Lunkad2021b.csv", - "histatin5_SoftMatter.txt": "Blanco2020a.csv"} + "histatin5_SoftMatter.txt": "Blanco2020a.csv", + "1beb-10mM-torres.dat": "Torres2017.csv", + "1f6s-10mM-torres.dat": "Torres2022.csv"} # Sanity checks if filename not in supported_filenames: @@ -37,27 +42,51 @@ ref_path=pmb.get_resource(f"testsuite/data/src/{filename}") Refs_lunkad=["Glu-HisMSDE.csv","Lys-AspMSDE.csv"] Ref_blanco=["histatin5_SoftMatter.txt"] + +Ref_torres = ["1f6s-10mM-torres.dat","1beb-10mM-torres.dat" ] Ref_landsgesell=["data_landsgesell.csv"] + if filename in Refs_lunkad: data=pd.read_csv(ref_path) Z_ref = 5*-1*data['aaa']+5*data['aab'] # Error propagation calculation # 1/4 factor added to correct for bug in the original calculation of the error reported by the authors Z_ref_err = 5/4*np.sqrt((data['eaa'])**2+(data['eab'])**2) + pH_range = np.linspace(2, 12, num=21) elif filename in Ref_blanco: data=np.loadtxt(ref_path, delimiter=",") Z_ref=data[:,1] Z_ref_err=data[:,2] + pH_range = np.linspace(2, 12, num=21) + +elif filename in Ref_torres: + + Z_ref = [] + Z_ref_err = [] + pH_range = [] + + with open (ref_path,'r') as file: + for line in file: + line_split = line.split () + pH = float (line_split[0]) + pH_range.append(pH) + Z_ref.append (float(line_split[1])) + Z_ref_err.append(float(line_split[2])) + elif filename in Ref_landsgesell: data = pd.read_csv(ref_path, sep="\t", index_col=False) - else: raise RuntimeError() +# Store the data +data=pd.DataFrame({"pH": pH_range, + "charge": Z_ref, + "charge_error": Z_ref_err}) + if filename in Refs_lunkad+Ref_blanco: pH_range = np.linspace(2, 12, num=21) @@ -66,6 +95,7 @@ "charge": Z_ref, "charge_error": Z_ref_err}) + data_path=pmb.get_resource(f"testsuite/data") data.to_csv(f"{data_path}/{output_filenames[filename]}", index=False) diff --git a/parameters/globular_proteins/1beb.vtf b/parameters/globular_proteins/1beb.vtf index ceb4d33..082f860 100644 --- a/parameters/globular_proteins/1beb.vtf +++ b/parameters/globular_proteins/1beb.vtf @@ -1,313 +1,313 @@ atom 1 name n resname n resid 5 chain A radius 0.7 atom 2 name CA resname GLN resid 5 chain A radius 0.7 -atom 3 name Q resname GLN resid 5 chain A radius 1.7529 +atom 3 name Q resname GLN resid 5 chain A radius 2.0762 atom 4 name CA resname THR resid 6 chain A radius 0.7 -atom 5 name T resname THR resid 6 chain A radius 1.6274 +atom 5 name T resname THR resid 6 chain A radius 1.7144 atom 6 name CA resname MET resid 7 chain A radius 0.7 -atom 7 name M resname MET resid 7 chain A radius 2.5388 -atom 8 name K resname LYS resid 8 chain A radius 2.1978 +atom 7 name M resname MET resid 7 chain A radius 2.292 +atom 8 name K resname LYS resid 8 chain A radius 2.426 atom 9 name CA resname LYS resid 8 chain A radius 0.7 atom 10 name CA resname GLY resid 9 chain A radius 0.7 -atom 11 name L resname LEU resid 10 chain A radius 2.1098 +atom 11 name L resname LEU resid 10 chain A radius 1.962 atom 12 name CA resname LEU resid 10 chain A radius 0.7 -atom 13 name D resname ASP resid 11 chain A radius 2.1115 +atom 13 name D resname ASP resid 11 chain A radius 1.9682 atom 14 name CA resname ASP resid 11 chain A radius 0.7 -atom 15 name I resname ILE resid 12 chain A radius 1.9865 +atom 15 name I resname ILE resid 12 chain A radius 1.928 atom 16 name CA resname ILE resid 12 chain A radius 0.7 atom 17 name CA resname GLN resid 13 chain A radius 0.7 -atom 18 name Q resname GLN resid 13 chain A radius 2.0303 +atom 18 name Q resname GLN resid 13 chain A radius 2.0762 atom 19 name CA resname LYS resid 14 chain A radius 0.7 -atom 20 name K resname LYS resid 14 chain A radius 2.4453 +atom 20 name K resname LYS resid 14 chain A radius 2.426 atom 21 name CA resname VAL resid 15 chain A radius 0.7 -atom 22 name V resname VAL resid 15 chain A radius 1.6169 -atom 23 name A resname ALA resid 16 chain A radius 1.7709 +atom 22 name V resname VAL resid 15 chain A radius 1.7836 +atom 23 name A resname ALA resid 16 chain A radius 1.9308 atom 24 name CA resname ALA resid 16 chain A radius 0.7 atom 25 name CA resname GLY resid 17 chain A radius 0.7 atom 26 name CA resname THR resid 18 chain A radius 0.7 -atom 27 name T resname THR resid 18 chain A radius 1.7866 +atom 27 name T resname THR resid 18 chain A radius 1.7144 atom 28 name CA resname TRP resid 19 chain A radius 0.7 -atom 29 name W resname TRP resid 19 chain A radius 2.4949 -atom 30 name Y resname TYR resid 20 chain A radius 2.3941 +atom 29 name W resname TRP resid 19 chain A radius 2.513 +atom 30 name Y resname TYR resid 20 chain A radius 2.3169 atom 31 name CA resname TYR resid 20 chain A radius 0.7 -atom 32 name S resname SER resid 21 chain A radius 1.567 +atom 32 name S resname SER resid 21 chain A radius 1.5619 atom 33 name CA resname SER resid 21 chain A radius 0.7 -atom 34 name L resname LEU resid 22 chain A radius 2.0989 +atom 34 name L resname LEU resid 22 chain A radius 1.962 atom 35 name CA resname LEU resid 22 chain A radius 0.7 -atom 36 name A resname ALA resid 23 chain A radius 2.0881 +atom 36 name A resname ALA resid 23 chain A radius 1.9308 atom 37 name CA resname ALA resid 23 chain A radius 0.7 -atom 38 name M resname MET resid 24 chain A radius 2.3245 +atom 38 name M resname MET resid 24 chain A radius 2.292 atom 39 name CA resname MET resid 24 chain A radius 0.7 -atom 40 name A resname ALA resid 25 chain A radius 2.1035 +atom 40 name A resname ALA resid 25 chain A radius 1.9308 atom 41 name CA resname ALA resid 25 chain A radius 0.7 atom 42 name CA resname ALA resid 26 chain A radius 0.7 -atom 43 name A resname ALA resid 26 chain A radius 2.0478 +atom 43 name A resname ALA resid 26 chain A radius 1.9308 atom 44 name CA resname SER resid 27 chain A radius 0.7 -atom 45 name S resname SER resid 27 chain A radius 1.4179 +atom 45 name S resname SER resid 27 chain A radius 1.5619 atom 46 name CA resname ASP resid 28 chain A radius 0.7 -atom 47 name D resname ASP resid 28 chain A radius 2.1822 +atom 47 name D resname ASP resid 28 chain A radius 1.9682 atom 48 name CA resname ILE resid 29 chain A radius 0.7 -atom 49 name I resname ILE resid 29 chain A radius 1.8051 -atom 50 name S resname SER resid 30 chain A radius 1.4884 +atom 49 name I resname ILE resid 29 chain A radius 1.928 +atom 50 name S resname SER resid 30 chain A radius 1.5619 atom 51 name CA resname SER resid 30 chain A radius 0.7 atom 52 name CA resname LEU resid 31 chain A radius 0.7 -atom 53 name L resname LEU resid 31 chain A radius 1.8032 +atom 53 name L resname LEU resid 31 chain A radius 1.962 atom 54 name CA resname LEU resid 32 chain A radius 0.7 -atom 55 name L resname LEU resid 32 chain A radius 2.0381 +atom 55 name L resname LEU resid 32 chain A radius 1.962 atom 56 name CA resname ASP resid 33 chain A radius 0.7 -atom 57 name D resname ASP resid 33 chain A radius 2.0764 +atom 57 name D resname ASP resid 33 chain A radius 1.9682 atom 58 name CA resname ALA resid 34 chain A radius 0.7 -atom 59 name A resname ALA resid 34 chain A radius 2.3131 -atom 60 name Q resname GLN resid 35 chain A radius 2.0986 +atom 59 name A resname ALA resid 34 chain A radius 1.9308 +atom 60 name Q resname GLN resid 35 chain A radius 2.0762 atom 61 name CA resname GLN resid 35 chain A radius 0.7 atom 62 name CA resname SER resid 36 chain A radius 0.7 -atom 63 name S resname SER resid 36 chain A radius 1.4743 -atom 64 name A resname ALA resid 37 chain A radius 1.802 +atom 63 name S resname SER resid 36 chain A radius 1.5619 +atom 64 name A resname ALA resid 37 chain A radius 1.9308 atom 65 name CA resname ALA resid 37 chain A radius 0.7 -atom 66 name P resname PRO resid 38 chain A radius 1.0862 +atom 66 name P resname PRO resid 38 chain A radius 1.0673 atom 67 name CA resname PRO resid 38 chain A radius 0.7 atom 68 name CA resname LEU resid 39 chain A radius 0.7 -atom 69 name L resname LEU resid 39 chain A radius 2.1032 +atom 69 name L resname LEU resid 39 chain A radius 1.962 atom 70 name CA resname ARG resid 40 chain A radius 0.7 -atom 71 name R resname ARG resid 40 chain A radius 2.7788 -atom 72 name V resname VAL resid 41 chain A radius 1.7279 +atom 71 name R resname ARG resid 40 chain A radius 2.7458 +atom 72 name V resname VAL resid 41 chain A radius 1.7836 atom 73 name CA resname VAL resid 41 chain A radius 0.7 -atom 74 name Y resname TYR resid 42 chain A radius 2.2705 +atom 74 name Y resname TYR resid 42 chain A radius 2.3169 atom 75 name CA resname TYR resid 42 chain A radius 0.7 -atom 76 name V resname VAL resid 43 chain A radius 1.7527 +atom 76 name V resname VAL resid 43 chain A radius 1.7836 atom 77 name CA resname VAL resid 43 chain A radius 0.7 -atom 78 name E resname GLU resid 44 chain A radius 2.2208 +atom 78 name E resname GLU resid 44 chain A radius 2.1484 atom 79 name CA resname GLU resid 44 chain A radius 0.7 -atom 80 name E resname GLU resid 45 chain A radius 2.4514 +atom 80 name E resname GLU resid 45 chain A radius 2.1484 atom 81 name CA resname GLU resid 45 chain A radius 0.7 -atom 82 name L resname LEU resid 46 chain A radius 1.9982 +atom 82 name L resname LEU resid 46 chain A radius 1.962 atom 83 name CA resname LEU resid 46 chain A radius 0.7 atom 84 name CA resname LYS resid 47 chain A radius 0.7 -atom 85 name K resname LYS resid 47 chain A radius 2.2332 -atom 86 name P resname PRO resid 48 chain A radius 1.0658 +atom 85 name K resname LYS resid 47 chain A radius 2.426 +atom 86 name P resname PRO resid 48 chain A radius 1.0673 atom 87 name CA resname PRO resid 48 chain A radius 0.7 atom 88 name CA resname THR resid 49 chain A radius 0.7 -atom 89 name T resname THR resid 49 chain A radius 1.561 -atom 90 name P resname PRO resid 50 chain A radius 1.0602 +atom 89 name T resname THR resid 49 chain A radius 1.7144 +atom 90 name P resname PRO resid 50 chain A radius 1.0673 atom 91 name CA resname PRO resid 50 chain A radius 0.7 -atom 92 name E resname GLU resid 51 chain A radius 2.0939 +atom 92 name E resname GLU resid 51 chain A radius 2.1484 atom 93 name CA resname GLU resid 51 chain A radius 0.7 atom 94 name CA resname GLY resid 52 chain A radius 0.7 atom 95 name CA resname ASP resid 53 chain A radius 0.7 -atom 96 name D resname ASP resid 53 chain A radius 1.6812 +atom 96 name D resname ASP resid 53 chain A radius 1.9682 atom 97 name CA resname LEU resid 54 chain A radius 0.7 -atom 98 name L resname LEU resid 54 chain A radius 2.2062 +atom 98 name L resname LEU resid 54 chain A radius 1.962 atom 99 name CA resname GLU resid 55 chain A radius 0.7 -atom 100 name E resname GLU resid 55 chain A radius 2.2409 +atom 100 name E resname GLU resid 55 chain A radius 2.1484 atom 101 name CA resname ILE resid 56 chain A radius 0.7 -atom 102 name I resname ILE resid 56 chain A radius 1.9905 -atom 103 name L resname LEU resid 57 chain A radius 1.8111 +atom 102 name I resname ILE resid 56 chain A radius 1.928 +atom 103 name L resname LEU resid 57 chain A radius 1.962 atom 104 name CA resname LEU resid 57 chain A radius 0.7 atom 105 name CA resname LEU resid 58 chain A radius 0.7 -atom 106 name L resname LEU resid 58 chain A radius 1.8939 -atom 107 name Q resname GLN resid 59 chain A radius 2.126 +atom 106 name L resname LEU resid 58 chain A radius 1.962 +atom 107 name Q resname GLN resid 59 chain A radius 2.0762 atom 108 name CA resname GLN resid 59 chain A radius 0.7 atom 109 name CA resname LYS resid 60 chain A radius 0.7 -atom 110 name K resname LYS resid 60 chain A radius 2.8568 +atom 110 name K resname LYS resid 60 chain A radius 2.426 atom 111 name CA resname TRP resid 61 chain A radius 0.7 -atom 112 name W resname TRP resid 61 chain A radius 2.5312 -atom 113 name E resname GLU resid 62 chain A radius 2.2816 +atom 112 name W resname TRP resid 61 chain A radius 2.513 +atom 113 name E resname GLU resid 62 chain A radius 2.1484 atom 114 name CA resname GLU resid 62 chain A radius 0.7 -atom 115 name N resname ASN resid 63 chain A radius 2.1098 +atom 115 name N resname ASN resid 63 chain A radius 1.9287 atom 116 name CA resname ASN resid 63 chain A radius 0.7 atom 117 name CA resname GLY resid 64 chain A radius 0.7 -atom 118 name E resname GLU resid 65 chain A radius 1.9038 +atom 118 name E resname GLU resid 65 chain A radius 2.1484 atom 119 name CA resname GLU resid 65 chain A radius 0.7 atom 120 name CA resname CYS resid 66 chain A radius 0.7 -atom 121 name C resname CYS resid 66 chain A radius 2.3826 -atom 122 name A resname ALA resid 67 chain A radius 1.8 +atom 121 name C resname CYS resid 66 chain A radius 2.2244 +atom 122 name A resname ALA resid 67 chain A radius 1.9308 atom 123 name CA resname ALA resid 67 chain A radius 0.7 -atom 124 name Q resname GLN resid 68 chain A radius 2.274 +atom 124 name Q resname GLN resid 68 chain A radius 2.0762 atom 125 name CA resname GLN resid 68 chain A radius 0.7 -atom 126 name K resname LYS resid 69 chain A radius 2.3347 +atom 126 name K resname LYS resid 69 chain A radius 2.426 atom 127 name CA resname LYS resid 69 chain A radius 0.7 -atom 128 name K resname LYS resid 70 chain A radius 2.6704 +atom 128 name K resname LYS resid 70 chain A radius 2.426 atom 129 name CA resname LYS resid 70 chain A radius 0.7 -atom 130 name I resname ILE resid 71 chain A radius 1.9378 +atom 130 name I resname ILE resid 71 chain A radius 1.928 atom 131 name CA resname ILE resid 71 chain A radius 0.7 atom 132 name CA resname ILE resid 72 chain A radius 0.7 -atom 133 name I resname ILE resid 72 chain A radius 1.8471 -atom 134 name A resname ALA resid 73 chain A radius 1.9011 +atom 133 name I resname ILE resid 72 chain A radius 1.928 +atom 134 name A resname ALA resid 73 chain A radius 1.9308 atom 135 name CA resname ALA resid 73 chain A radius 0.7 -atom 136 name E resname GLU resid 74 chain A radius 2.1413 +atom 136 name E resname GLU resid 74 chain A radius 2.1484 atom 137 name CA resname GLU resid 74 chain A radius 0.7 -atom 138 name K resname LYS resid 75 chain A radius 2.5177 +atom 138 name K resname LYS resid 75 chain A radius 2.426 atom 139 name CA resname LYS resid 75 chain A radius 0.7 -atom 140 name T resname THR resid 76 chain A radius 1.6946 +atom 140 name T resname THR resid 76 chain A radius 1.7144 atom 141 name CA resname THR resid 76 chain A radius 0.7 -atom 142 name K resname LYS resid 77 chain A radius 2.616 +atom 142 name K resname LYS resid 77 chain A radius 2.426 atom 143 name CA resname LYS resid 77 chain A radius 0.7 atom 144 name CA resname ILE resid 78 chain A radius 0.7 -atom 145 name I resname ILE resid 78 chain A radius 1.8275 +atom 145 name I resname ILE resid 78 chain A radius 1.928 atom 146 name CA resname PRO resid 79 chain A radius 0.7 -atom 147 name P resname PRO resid 79 chain A radius 1.0586 +atom 147 name P resname PRO resid 79 chain A radius 1.0673 atom 148 name CA resname ALA resid 80 chain A radius 0.7 -atom 149 name A resname ALA resid 80 chain A radius 1.8231 -atom 150 name V resname VAL resid 81 chain A radius 1.9232 +atom 149 name A resname ALA resid 80 chain A radius 1.9308 +atom 150 name V resname VAL resid 81 chain A radius 1.7836 atom 151 name CA resname VAL resid 81 chain A radius 0.7 -atom 152 name F resname PHE resid 82 chain A radius 2.1184 +atom 152 name F resname PHE resid 82 chain A radius 2.125 atom 153 name CA resname PHE resid 82 chain A radius 0.7 -atom 154 name K resname LYS resid 83 chain A radius 2.5635 +atom 154 name K resname LYS resid 83 chain A radius 2.426 atom 155 name CA resname LYS resid 83 chain A radius 0.7 -atom 156 name I resname ILE resid 84 chain A radius 1.9005 +atom 156 name I resname ILE resid 84 chain A radius 1.928 atom 157 name CA resname ILE resid 84 chain A radius 0.7 -atom 158 name D resname ASP resid 85 chain A radius 2.1715 +atom 158 name D resname ASP resid 85 chain A radius 1.9682 atom 159 name CA resname ASP resid 85 chain A radius 0.7 -atom 160 name A resname ALA resid 86 chain A radius 2.175 +atom 160 name A resname ALA resid 86 chain A radius 1.9308 atom 161 name CA resname ALA resid 86 chain A radius 0.7 -atom 162 name L resname LEU resid 87 chain A radius 1.982 +atom 162 name L resname LEU resid 87 chain A radius 1.962 atom 163 name CA resname LEU resid 87 chain A radius 0.7 atom 164 name CA resname ASN resid 88 chain A radius 0.7 -atom 165 name N resname ASN resid 88 chain A radius 1.8798 -atom 166 name E resname GLU resid 89 chain A radius 2.0472 +atom 165 name N resname ASN resid 88 chain A radius 1.9287 +atom 166 name E resname GLU resid 89 chain A radius 2.1484 atom 167 name CA resname GLU resid 89 chain A radius 0.7 atom 168 name CA resname ASN resid 90 chain A radius 0.7 -atom 169 name N resname ASN resid 90 chain A radius 1.842 -atom 170 name K resname LYS resid 91 chain A radius 2.3383 +atom 169 name N resname ASN resid 90 chain A radius 1.9287 +atom 170 name K resname LYS resid 91 chain A radius 2.426 atom 171 name CA resname LYS resid 91 chain A radius 0.7 atom 172 name CA resname VAL resid 92 chain A radius 0.7 -atom 173 name V resname VAL resid 92 chain A radius 1.894 +atom 173 name V resname VAL resid 92 chain A radius 1.7836 atom 174 name CA resname LEU resid 93 chain A radius 0.7 -atom 175 name L resname LEU resid 93 chain A radius 1.762 +atom 175 name L resname LEU resid 93 chain A radius 1.962 atom 176 name CA resname VAL resid 94 chain A radius 0.7 -atom 177 name V resname VAL resid 94 chain A radius 1.8066 -atom 178 name L resname LEU resid 95 chain A radius 1.834 +atom 177 name V resname VAL resid 94 chain A radius 1.7836 +atom 178 name L resname LEU resid 95 chain A radius 1.962 atom 179 name CA resname LEU resid 95 chain A radius 0.7 -atom 180 name D resname ASP resid 96 chain A radius 2.2665 +atom 180 name D resname ASP resid 96 chain A radius 1.9682 atom 181 name CA resname ASP resid 96 chain A radius 0.7 atom 182 name CA resname THR resid 97 chain A radius 0.7 -atom 183 name T resname THR resid 97 chain A radius 1.9769 -atom 184 name D resname ASP resid 98 chain A radius 1.6174 +atom 183 name T resname THR resid 97 chain A radius 1.7144 +atom 184 name D resname ASP resid 98 chain A radius 1.9682 atom 185 name CA resname ASP resid 98 chain A radius 0.7 atom 186 name CA resname TYR resid 99 chain A radius 0.7 -atom 187 name Y resname TYR resid 99 chain A radius 2.3299 +atom 187 name Y resname TYR resid 99 chain A radius 2.3169 atom 188 name CA resname LYS resid 100 chain A radius 0.7 -atom 189 name K resname LYS resid 100 chain A radius 2.4422 +atom 189 name K resname LYS resid 100 chain A radius 2.426 atom 190 name CA resname LYS resid 101 chain A radius 0.7 -atom 191 name K resname LYS resid 101 chain A radius 2.338 +atom 191 name K resname LYS resid 101 chain A radius 2.426 atom 192 name CA resname TYR resid 102 chain A radius 0.7 -atom 193 name Y resname TYR resid 102 chain A radius 2.273 -atom 194 name L resname LEU resid 103 chain A radius 2.2432 +atom 193 name Y resname TYR resid 102 chain A radius 2.3169 +atom 194 name L resname LEU resid 103 chain A radius 1.962 atom 195 name CA resname LEU resid 103 chain A radius 0.7 -atom 196 name L resname LEU resid 104 chain A radius 1.9086 +atom 196 name L resname LEU resid 104 chain A radius 1.962 atom 197 name CA resname LEU resid 104 chain A radius 0.7 -atom 198 name F resname PHE resid 105 chain A radius 2.0252 +atom 198 name F resname PHE resid 105 chain A radius 2.125 atom 199 name CA resname PHE resid 105 chain A radius 0.7 -atom 200 name C resname CYS resid 106 chain A radius 2.1346 +atom 200 name C resname CYS resid 106 chain A radius 2.2244 atom 201 name CA resname CYS resid 106 chain A radius 0.7 -atom 202 name M resname MET resid 107 chain A radius 2.1924 +atom 202 name M resname MET resid 107 chain A radius 2.292 atom 203 name CA resname MET resid 107 chain A radius 0.7 -atom 204 name E resname GLU resid 108 chain A radius 2.2455 +atom 204 name E resname GLU resid 108 chain A radius 2.1484 atom 205 name CA resname GLU resid 108 chain A radius 0.7 atom 206 name CA resname ASN resid 109 chain A radius 0.7 -atom 207 name N resname ASN resid 109 chain A radius 2.0979 -atom 208 name S resname SER resid 110 chain A radius 1.4711 +atom 207 name N resname ASN resid 109 chain A radius 1.9287 +atom 208 name S resname SER resid 110 chain A radius 1.5619 atom 209 name CA resname SER resid 110 chain A radius 0.7 atom 210 name CA resname ALA resid 111 chain A radius 0.7 -atom 211 name A resname ALA resid 111 chain A radius 1.7895 -atom 212 name E resname GLU resid 112 chain A radius 2.3384 +atom 211 name A resname ALA resid 111 chain A radius 1.9308 +atom 212 name E resname GLU resid 112 chain A radius 2.1484 atom 213 name CA resname GLU resid 112 chain A radius 0.7 -atom 214 name P resname PRO resid 113 chain A radius 1.0487 +atom 214 name P resname PRO resid 113 chain A radius 1.0673 atom 215 name CA resname PRO resid 113 chain A radius 0.7 -atom 216 name E resname GLU resid 114 chain A radius 2.0242 +atom 216 name E resname GLU resid 114 chain A radius 2.1484 atom 217 name CA resname GLU resid 114 chain A radius 0.7 atom 218 name CA resname GLN resid 115 chain A radius 0.7 -atom 219 name Q resname GLN resid 115 chain A radius 2.0687 +atom 219 name Q resname GLN resid 115 chain A radius 2.0762 atom 220 name CA resname SER resid 116 chain A radius 0.7 -atom 221 name S resname SER resid 116 chain A radius 1.9106 -atom 222 name L resname LEU resid 117 chain A radius 2.0678 +atom 221 name S resname SER resid 116 chain A radius 1.5619 +atom 222 name L resname LEU resid 117 chain A radius 1.962 atom 223 name CA resname LEU resid 117 chain A radius 0.7 atom 224 name CA resname VAL resid 118 chain A radius 0.7 -atom 225 name V resname VAL resid 118 chain A radius 1.8723 +atom 225 name V resname VAL resid 118 chain A radius 1.7836 atom 226 name CA resname CYS resid 119 chain A radius 0.7 -atom 227 name C resname CYS resid 119 chain A radius 2.0322 +atom 227 name C resname CYS resid 119 chain A radius 2.2244 atom 228 name CA resname GLN resid 120 chain A radius 0.7 -atom 229 name Q resname GLN resid 120 chain A radius 2.2962 +atom 229 name Q resname GLN resid 120 chain A radius 2.0762 atom 230 name CA resname CYS resid 121 chain A radius 0.7 -atom 231 name C resname CYS resid 121 chain A radius 2.4131 +atom 231 name C resname CYS resid 121 chain A radius 2.2244 atom 232 name CA resname LEU resid 122 chain A radius 0.7 -atom 233 name L resname LEU resid 122 chain A radius 1.8981 -atom 234 name V resname VAL resid 123 chain A radius 1.7347 +atom 233 name L resname LEU resid 122 chain A radius 1.962 +atom 234 name V resname VAL resid 123 chain A radius 1.7836 atom 235 name CA resname VAL resid 123 chain A radius 0.7 atom 236 name CA resname ARG resid 124 chain A radius 0.7 -atom 237 name R resname ARG resid 124 chain A radius 2.7062 -atom 238 name T resname THR resid 125 chain A radius 1.6558 +atom 237 name R resname ARG resid 124 chain A radius 2.7458 +atom 238 name T resname THR resid 125 chain A radius 1.7144 atom 239 name CA resname THR resid 125 chain A radius 0.7 -atom 240 name P resname PRO resid 126 chain A radius 1.0687 +atom 240 name P resname PRO resid 126 chain A radius 1.0673 atom 241 name CA resname PRO resid 126 chain A radius 0.7 -atom 242 name E resname GLU resid 127 chain A radius 2.1915 +atom 242 name E resname GLU resid 127 chain A radius 2.1484 atom 243 name CA resname GLU resid 127 chain A radius 0.7 atom 244 name CA resname VAL resid 128 chain A radius 0.7 -atom 245 name V resname VAL resid 128 chain A radius 1.7239 +atom 245 name V resname VAL resid 128 chain A radius 1.7836 atom 246 name CA resname ASP resid 129 chain A radius 0.7 -atom 247 name D resname ASP resid 129 chain A radius 2.1124 +atom 247 name D resname ASP resid 129 chain A radius 1.9682 atom 248 name CA resname ASP resid 130 chain A radius 0.7 -atom 249 name D resname ASP resid 130 chain A radius 1.7354 -atom 250 name E resname GLU resid 131 chain A radius 1.8627 +atom 249 name D resname ASP resid 130 chain A radius 1.9682 +atom 250 name E resname GLU resid 131 chain A radius 2.1484 atom 251 name CA resname GLU resid 131 chain A radius 0.7 -atom 252 name A resname ALA resid 132 chain A radius 1.7716 +atom 252 name A resname ALA resid 132 chain A radius 1.9308 atom 253 name CA resname ALA resid 132 chain A radius 0.7 atom 254 name CA resname LEU resid 133 chain A radius 0.7 -atom 255 name L resname LEU resid 133 chain A radius 1.9051 +atom 255 name L resname LEU resid 133 chain A radius 1.962 atom 256 name CA resname GLU resid 134 chain A radius 0.7 -atom 257 name E resname GLU resid 134 chain A radius 2.2117 -atom 258 name K resname LYS resid 135 chain A radius 2.3633 +atom 257 name E resname GLU resid 134 chain A radius 2.1484 +atom 258 name K resname LYS resid 135 chain A radius 2.426 atom 259 name CA resname LYS resid 135 chain A radius 0.7 -atom 260 name F resname PHE resid 136 chain A radius 2.3347 +atom 260 name F resname PHE resid 136 chain A radius 2.125 atom 261 name CA resname PHE resid 136 chain A radius 0.7 -atom 262 name D resname ASP resid 137 chain A radius 1.7272 +atom 262 name D resname ASP resid 137 chain A radius 1.9682 atom 263 name CA resname ASP resid 137 chain A radius 0.7 atom 264 name CA resname LYS resid 138 chain A radius 0.7 -atom 265 name K resname LYS resid 138 chain A radius 2.2232 +atom 265 name K resname LYS resid 138 chain A radius 2.426 atom 266 name CA resname ALA resid 139 chain A radius 0.7 -atom 267 name A resname ALA resid 139 chain A radius 1.7797 -atom 268 name L resname LEU resid 140 chain A radius 1.8351 +atom 267 name A resname ALA resid 139 chain A radius 1.9308 +atom 268 name L resname LEU resid 140 chain A radius 1.962 atom 269 name CA resname LEU resid 140 chain A radius 0.7 -atom 270 name K resname LYS resid 141 chain A radius 2.2503 +atom 270 name K resname LYS resid 141 chain A radius 2.426 atom 271 name CA resname LYS resid 141 chain A radius 0.7 atom 272 name CA resname ALA resid 142 chain A radius 0.7 -atom 273 name A resname ALA resid 142 chain A radius 1.8665 -atom 274 name L resname LEU resid 143 chain A radius 1.8574 +atom 273 name A resname ALA resid 142 chain A radius 1.9308 +atom 274 name L resname LEU resid 143 chain A radius 1.962 atom 275 name CA resname LEU resid 143 chain A radius 0.7 -atom 276 name P resname PRO resid 144 chain A radius 1.073 +atom 276 name P resname PRO resid 144 chain A radius 1.0673 atom 277 name CA resname PRO resid 144 chain A radius 0.7 -atom 278 name M resname MET resid 145 chain A radius 2.1123 +atom 278 name M resname MET resid 145 chain A radius 2.292 atom 279 name CA resname MET resid 145 chain A radius 0.7 atom 280 name CA resname HIS resid 146 chain A radius 0.7 atom 281 name H resname HIS resid 146 chain A radius 2.0562 -atom 282 name I resname ILE resid 147 chain A radius 2.1292 +atom 282 name I resname ILE resid 147 chain A radius 1.928 atom 283 name CA resname ILE resid 147 chain A radius 0.7 -atom 284 name R resname ARG resid 148 chain A radius 2.7525 +atom 284 name R resname ARG resid 148 chain A radius 2.7458 atom 285 name CA resname ARG resid 148 chain A radius 0.7 -atom 286 name L resname LEU resid 149 chain A radius 1.985 +atom 286 name L resname LEU resid 149 chain A radius 1.962 atom 287 name CA resname LEU resid 149 chain A radius 0.7 -atom 288 name S resname SER resid 150 chain A radius 1.6043 +atom 288 name S resname SER resid 150 chain A radius 1.5619 atom 289 name CA resname SER resid 150 chain A radius 0.7 atom 290 name CA resname PHE resid 151 chain A radius 0.7 -atom 291 name F resname PHE resid 151 chain A radius 2.0218 -atom 292 name N resname ASN resid 152 chain A radius 1.7139 +atom 291 name F resname PHE resid 151 chain A radius 2.125 +atom 292 name N resname ASN resid 152 chain A radius 1.9287 atom 293 name CA resname ASN resid 152 chain A radius 0.7 -atom 294 name P resname PRO resid 153 chain A radius 1.0772 +atom 294 name P resname PRO resid 153 chain A radius 1.0673 atom 295 name CA resname PRO resid 153 chain A radius 0.7 -atom 296 name T resname THR resid 154 chain A radius 1.6983 +atom 296 name T resname THR resid 154 chain A radius 1.7144 atom 297 name CA resname THR resid 154 chain A radius 0.7 -atom 298 name Q resname GLN resid 155 chain A radius 1.9845 +atom 298 name Q resname GLN resid 155 chain A radius 2.0762 atom 299 name CA resname GLN resid 155 chain A radius 0.7 -atom 300 name L resname LEU resid 156 chain A radius 1.8614 +atom 300 name L resname LEU resid 156 chain A radius 1.962 atom 301 name CA resname LEU resid 156 chain A radius 0.7 -atom 302 name E resname GLU resid 157 chain A radius 1.9441 +atom 302 name E resname GLU resid 157 chain A radius 2.1484 atom 303 name CA resname GLU resid 157 chain A radius 0.7 -atom 304 name E resname GLU resid 158 chain A radius 2.1758 +atom 304 name E resname GLU resid 158 chain A radius 2.1484 atom 305 name CA resname GLU resid 158 chain A radius 0.7 atom 306 name CA resname GLN resid 159 chain A radius 0.7 -atom 307 name Q resname GLN resid 159 chain A radius 2.0549 +atom 307 name Q resname GLN resid 159 chain A radius 2.0762 atom 308 name CA resname CYS resid 160 chain A radius 0.7 atom 309 name c resname c resid 160 chain A radius 0.7 -atom 310 name C resname CYS resid 160 chain A radius 2.1595 +atom 310 name C resname CYS resid 160 chain A radius 2.2244 bond 2:4 bond 4:6 bond 6:9 diff --git a/parameters/globular_proteins/1f6s.vtf b/parameters/globular_proteins/1f6s.vtf index 6558b23..1820255 100644 --- a/parameters/globular_proteins/1f6s.vtf +++ b/parameters/globular_proteins/1f6s.vtf @@ -1,242 +1,242 @@ atom 1 name n resname n resid 1 chain A radius 0.7 -atom 2 name E resname GLU resid 1 chain A radius 1.4354 +atom 2 name E resname GLU resid 1 chain A radius 1.3735 atom 3 name CA resname GLU resid 1 chain A radius 0.7 atom 4 name CA resname GLN resid 2 chain A radius 0.7 -atom 5 name Q resname GLN resid 2 chain A radius 1.4529 +atom 5 name Q resname GLN resid 2 chain A radius 1.4504 atom 6 name CA resname LEU resid 3 chain A radius 0.7 -atom 7 name L resname LEU resid 3 chain A radius 1.2695 +atom 7 name L resname LEU resid 3 chain A radius 1.2668 atom 8 name CA resname THR resid 4 chain A radius 0.7 -atom 9 name T resname THR resid 4 chain A radius 1.0729 +atom 9 name T resname THR resid 4 chain A radius 1.0699 atom 10 name CA resname LYS resid 5 chain A radius 0.7 -atom 11 name K resname LYS resid 5 chain A radius 1.7109 +atom 11 name K resname LYS resid 5 chain A radius 1.7005 atom 12 name CA resname CYS resid 6 chain A radius 0.7 -atom 13 name C resname CYS resid 6 chain A radius 0.9978 -atom 14 name E resname GLU resid 7 chain A radius 1.438 +atom 13 name C resname CYS resid 6 chain A radius 1.0011 +atom 14 name E resname GLU resid 7 chain A radius 1.3735 atom 15 name CA resname GLU resid 7 chain A radius 0.7 atom 16 name CA resname VAL resid 8 chain A radius 0.7 -atom 17 name V resname VAL resid 8 chain A radius 1.0962 -atom 18 name F resname PHE resid 9 chain A radius 1.6407 +atom 17 name V resname VAL resid 8 chain A radius 1.0951 +atom 18 name F resname PHE resid 9 chain A radius 1.6426 atom 19 name CA resname PHE resid 9 chain A radius 0.7 atom 20 name R resname ARG resid 10 chain A radius 1.8294 atom 21 name CA resname ARG resid 10 chain A radius 0.7 -atom 22 name E resname GLU resid 11 chain A radius 1.4475 +atom 22 name E resname GLU resid 11 chain A radius 1.3735 atom 23 name CA resname GLU resid 11 chain A radius 0.7 -atom 24 name L resname LEU resid 12 chain A radius 1.2646 +atom 24 name L resname LEU resid 12 chain A radius 1.2668 atom 25 name CA resname LEU resid 12 chain A radius 0.7 -atom 26 name K resname LYS resid 13 chain A radius 1.818 +atom 26 name K resname LYS resid 13 chain A radius 1.7005 atom 27 name CA resname LYS resid 13 chain A radius 0.7 -atom 28 name D resname ASP resid 14 chain A radius 1.1628 +atom 28 name D resname ASP resid 14 chain A radius 1.165 atom 29 name CA resname ASP resid 14 chain A radius 0.7 -atom 30 name L resname LEU resid 15 chain A radius 1.2651 +atom 30 name L resname LEU resid 15 chain A radius 1.2668 atom 31 name CA resname LEU resid 15 chain A radius 0.7 -atom 32 name K resname LYS resid 16 chain A radius 1.8109 +atom 32 name K resname LYS resid 16 chain A radius 1.7005 atom 33 name CA resname LYS resid 16 chain A radius 0.7 atom 34 name CA resname GLY resid 17 chain A radius 0.7 -atom 35 name Y resname TYR resid 18 chain A radius 1.864 +atom 35 name Y resname TYR resid 18 chain A radius 1.8672 atom 36 name CA resname TYR resid 18 chain A radius 0.7 atom 37 name CA resname GLY resid 19 chain A radius 0.7 atom 38 name CA resname GLY resid 20 chain A radius 0.7 -atom 39 name V resname VAL resid 21 chain A radius 1.0944 +atom 39 name V resname VAL resid 21 chain A radius 1.0951 atom 40 name CA resname VAL resid 21 chain A radius 0.7 atom 41 name CA resname SER resid 22 chain A radius 0.7 -atom 42 name S resname SER resid 22 chain A radius 0.7129 +atom 42 name S resname SER resid 22 chain A radius 0.7151 atom 43 name CA resname LEU resid 23 chain A radius 0.7 -atom 44 name L resname LEU resid 23 chain A radius 1.2684 +atom 44 name L resname LEU resid 23 chain A radius 1.2668 atom 45 name CA resname PRO resid 24 chain A radius 0.7 -atom 46 name P resname PRO resid 24 chain A radius 1.0557 +atom 46 name P resname PRO resid 24 chain A radius 1.0533 atom 47 name CA resname GLU resid 25 chain A radius 0.7 -atom 48 name E resname GLU resid 25 chain A radius 1.4173 +atom 48 name E resname GLU resid 25 chain A radius 1.3735 atom 49 name CA resname TRP resid 26 chain A radius 0.7 -atom 50 name W resname TRP resid 26 chain A radius 2.0055 -atom 51 name V resname VAL resid 27 chain A radius 1.0997 +atom 50 name W resname TRP resid 26 chain A radius 2.0068 +atom 51 name V resname VAL resid 27 chain A radius 1.0951 atom 52 name CA resname VAL resid 27 chain A radius 0.7 atom 53 name CA resname CYS resid 28 chain A radius 0.7 -atom 54 name C resname CYS resid 28 chain A radius 1.003 -atom 55 name T resname THR resid 29 chain A radius 1.0716 +atom 54 name C resname CYS resid 28 chain A radius 1.0011 +atom 55 name T resname THR resid 29 chain A radius 1.0699 atom 56 name CA resname THR resid 29 chain A radius 0.7 -atom 57 name T resname THR resid 30 chain A radius 1.0709 +atom 57 name T resname THR resid 30 chain A radius 1.0699 atom 58 name CA resname THR resid 30 chain A radius 0.7 atom 59 name CA resname PHE resid 31 chain A radius 0.7 -atom 60 name F resname PHE resid 31 chain A radius 1.6397 -atom 61 name H resname HIS resid 32 chain A radius 1.4425 +atom 60 name F resname PHE resid 31 chain A radius 1.6426 +atom 61 name H resname HIS resid 32 chain A radius 1.4442 atom 62 name CA resname HIS resid 32 chain A radius 0.7 atom 63 name CA resname THR resid 33 chain A radius 0.7 -atom 64 name T resname THR resid 33 chain A radius 1.0674 +atom 64 name T resname THR resid 33 chain A radius 1.0699 atom 65 name CA resname SER resid 34 chain A radius 0.7 -atom 66 name S resname SER resid 34 chain A radius 0.7159 +atom 66 name S resname SER resid 34 chain A radius 0.7151 atom 67 name CA resname GLY resid 35 chain A radius 0.7 atom 68 name CA resname TYR resid 36 chain A radius 0.7 -atom 69 name Y resname TYR resid 36 chain A radius 1.8649 -atom 70 name D resname ASP resid 37 chain A radius 1.1636 +atom 69 name Y resname TYR resid 36 chain A radius 1.8672 +atom 70 name D resname ASP resid 37 chain A radius 1.165 atom 71 name CA resname ASP resid 37 chain A radius 0.7 atom 72 name CA resname THR resid 38 chain A radius 0.7 -atom 73 name T resname THR resid 38 chain A radius 1.0741 +atom 73 name T resname THR resid 38 chain A radius 1.0699 atom 74 name CA resname GLN resid 39 chain A radius 0.7 -atom 75 name Q resname GLN resid 39 chain A radius 1.4477 +atom 75 name Q resname GLN resid 39 chain A radius 1.4504 atom 76 name A resname ALA resid 40 chain A radius 1.0 atom 77 name CA resname ALA resid 40 chain A radius 0.7 atom 78 name CA resname ILE resid 41 chain A radius 0.7 -atom 79 name I resname ILE resid 41 chain A radius 1.3287 -atom 80 name V resname VAL resid 42 chain A radius 1.0974 +atom 79 name I resname ILE resid 41 chain A radius 1.3651 +atom 80 name V resname VAL resid 42 chain A radius 1.0951 atom 81 name CA resname VAL resid 42 chain A radius 0.7 -atom 82 name Q resname GLN resid 43 chain A radius 1.4441 +atom 82 name Q resname GLN resid 43 chain A radius 1.4504 atom 83 name CA resname GLN resid 43 chain A radius 0.7 -atom 84 name N resname ASN resid 44 chain A radius 1.1857 +atom 84 name N resname ASN resid 44 chain A radius 1.1832 atom 85 name CA resname ASN resid 44 chain A radius 0.7 -atom 86 name N resname ASN resid 45 chain A radius 1.1847 +atom 86 name N resname ASN resid 45 chain A radius 1.1832 atom 87 name CA resname ASN resid 45 chain A radius 0.7 -atom 88 name D resname ASP resid 46 chain A radius 1.1715 +atom 88 name D resname ASP resid 46 chain A radius 1.165 atom 89 name CA resname ASP resid 46 chain A radius 0.7 atom 90 name CA resname SER resid 47 chain A radius 0.7 -atom 91 name S resname SER resid 47 chain A radius 0.7139 -atom 92 name T resname THR resid 48 chain A radius 1.0645 +atom 91 name S resname SER resid 47 chain A radius 0.7151 +atom 92 name T resname THR resid 48 chain A radius 1.0699 atom 93 name CA resname THR resid 48 chain A radius 0.7 atom 94 name CA resname GLU resid 49 chain A radius 0.7 -atom 95 name E resname GLU resid 49 chain A radius 1.4391 -atom 96 name Y resname TYR resid 50 chain A radius 1.8651 +atom 95 name E resname GLU resid 49 chain A radius 1.3735 +atom 96 name Y resname TYR resid 50 chain A radius 1.8672 atom 97 name CA resname TYR resid 50 chain A radius 0.7 atom 98 name CA resname GLY resid 51 chain A radius 0.7 atom 99 name CA resname LEU resid 52 chain A radius 0.7 -atom 100 name L resname LEU resid 52 chain A radius 1.2678 +atom 100 name L resname LEU resid 52 chain A radius 1.2668 atom 101 name CA resname PHE resid 53 chain A radius 0.7 -atom 102 name F resname PHE resid 53 chain A radius 1.6472 +atom 102 name F resname PHE resid 53 chain A radius 1.6426 atom 103 name CA resname GLN resid 54 chain A radius 0.7 -atom 104 name Q resname GLN resid 54 chain A radius 1.4477 +atom 104 name Q resname GLN resid 54 chain A radius 1.4504 atom 105 name CA resname ILE resid 55 chain A radius 0.7 -atom 106 name I resname ILE resid 55 chain A radius 1.3634 -atom 107 name N resname ASN resid 56 chain A radius 1.1825 +atom 106 name I resname ILE resid 55 chain A radius 1.3651 +atom 107 name N resname ASN resid 56 chain A radius 1.1832 atom 108 name CA resname ASN resid 56 chain A radius 0.7 atom 109 name CA resname ASN resid 57 chain A radius 0.7 -atom 110 name N resname ASN resid 57 chain A radius 1.1815 -atom 111 name K resname LYS resid 58 chain A radius 1.7036 +atom 110 name N resname ASN resid 57 chain A radius 1.1832 +atom 111 name K resname LYS resid 58 chain A radius 1.7005 atom 112 name CA resname LYS resid 58 chain A radius 0.7 -atom 113 name I resname ILE resid 59 chain A radius 1.3329 +atom 113 name I resname ILE resid 59 chain A radius 1.3651 atom 114 name CA resname ILE resid 59 chain A radius 0.7 -atom 115 name W resname TRP resid 60 chain A radius 2.0084 +atom 115 name W resname TRP resid 60 chain A radius 2.0068 atom 116 name CA resname TRP resid 60 chain A radius 0.7 -atom 117 name C resname CYS resid 61 chain A radius 0.9993 +atom 117 name C resname CYS resid 61 chain A radius 1.0011 atom 118 name CA resname CYS resid 61 chain A radius 0.7 atom 119 name CA resname LYS resid 62 chain A radius 0.7 -atom 120 name K resname LYS resid 62 chain A radius 1.8343 -atom 121 name D resname ASP resid 63 chain A radius 1.1654 +atom 120 name K resname LYS resid 62 chain A radius 1.7005 +atom 121 name D resname ASP resid 63 chain A radius 1.165 atom 122 name CA resname ASP resid 63 chain A radius 0.7 -atom 123 name D resname ASP resid 64 chain A radius 1.163 +atom 123 name D resname ASP resid 64 chain A radius 1.165 atom 124 name CA resname ASP resid 64 chain A radius 0.7 -atom 125 name Q resname GLN resid 65 chain A radius 1.46 +atom 125 name Q resname GLN resid 65 chain A radius 1.4504 atom 126 name CA resname GLN resid 65 chain A radius 0.7 atom 127 name CA resname ASN resid 66 chain A radius 0.7 -atom 128 name N resname ASN resid 66 chain A radius 1.1826 +atom 128 name N resname ASN resid 66 chain A radius 1.1832 atom 129 name CA resname PRO resid 67 chain A radius 0.7 -atom 130 name P resname PRO resid 67 chain A radius 1.0509 +atom 130 name P resname PRO resid 67 chain A radius 1.0533 atom 131 name CA resname HIS resid 68 chain A radius 0.7 -atom 132 name H resname HIS resid 68 chain A radius 1.4445 -atom 133 name S resname SER resid 69 chain A radius 0.7175 +atom 132 name H resname HIS resid 68 chain A radius 1.4442 +atom 133 name S resname SER resid 69 chain A radius 0.7151 atom 134 name CA resname SER resid 69 chain A radius 0.7 atom 135 name CA resname SER resid 70 chain A radius 0.7 -atom 136 name S resname SER resid 70 chain A radius 0.7147 -atom 137 name N resname ASN resid 71 chain A radius 1.1801 +atom 136 name S resname SER resid 70 chain A radius 0.7151 +atom 137 name N resname ASN resid 71 chain A radius 1.1832 atom 138 name CA resname ASN resid 71 chain A radius 0.7 -atom 139 name I resname ILE resid 72 chain A radius 1.3532 +atom 139 name I resname ILE resid 72 chain A radius 1.3651 atom 140 name CA resname ILE resid 72 chain A radius 0.7 -atom 141 name C resname CYS resid 73 chain A radius 1.0 +atom 141 name C resname CYS resid 73 chain A radius 1.0011 atom 142 name CA resname CYS resid 73 chain A radius 0.7 -atom 143 name N resname ASN resid 74 chain A radius 1.1844 +atom 143 name N resname ASN resid 74 chain A radius 1.1832 atom 144 name CA resname ASN resid 74 chain A radius 0.7 -atom 145 name I resname ILE resid 75 chain A radius 1.3414 +atom 145 name I resname ILE resid 75 chain A radius 1.3651 atom 146 name CA resname ILE resid 75 chain A radius 0.7 atom 147 name CA resname SER resid 76 chain A radius 0.7 -atom 148 name S resname SER resid 76 chain A radius 0.715 +atom 148 name S resname SER resid 76 chain A radius 0.7151 atom 149 name CA resname CYS resid 77 chain A radius 0.7 -atom 150 name C resname CYS resid 77 chain A radius 1.0017 -atom 151 name D resname ASP resid 78 chain A radius 1.164 +atom 150 name C resname CYS resid 77 chain A radius 1.0011 +atom 151 name D resname ASP resid 78 chain A radius 1.165 atom 152 name CA resname ASP resid 78 chain A radius 0.7 atom 153 name CA resname LYS resid 79 chain A radius 0.7 -atom 154 name K resname LYS resid 79 chain A radius 1.8038 +atom 154 name K resname LYS resid 79 chain A radius 1.7005 atom 155 name CA resname PHE resid 80 chain A radius 0.7 -atom 156 name F resname PHE resid 80 chain A radius 1.6427 +atom 156 name F resname PHE resid 80 chain A radius 1.6426 atom 157 name CA resname LEU resid 81 chain A radius 0.7 -atom 158 name L resname LEU resid 81 chain A radius 1.2741 +atom 158 name L resname LEU resid 81 chain A radius 1.2668 atom 159 name CA resname ASP resid 82 chain A radius 0.7 -atom 160 name D resname ASP resid 82 chain A radius 1.1626 -atom 161 name D resname ASP resid 83 chain A radius 1.168 +atom 160 name D resname ASP resid 82 chain A radius 1.165 +atom 161 name D resname ASP resid 83 chain A radius 1.165 atom 162 name CA resname ASP resid 83 chain A radius 0.7 atom 163 name CA resname ASP resid 84 chain A radius 0.7 -atom 164 name D resname ASP resid 84 chain A radius 1.1587 -atom 165 name L resname LEU resid 85 chain A radius 1.2647 +atom 164 name D resname ASP resid 84 chain A radius 1.165 +atom 165 name L resname LEU resid 85 chain A radius 1.2668 atom 166 name CA resname LEU resid 85 chain A radius 0.7 -atom 167 name T resname THR resid 86 chain A radius 1.0682 +atom 167 name T resname THR resid 86 chain A radius 1.0699 atom 168 name CA resname THR resid 86 chain A radius 0.7 atom 169 name CA resname ASP resid 87 chain A radius 0.7 -atom 170 name D resname ASP resid 87 chain A radius 1.169 -atom 171 name D resname ASP resid 88 chain A radius 1.1647 +atom 170 name D resname ASP resid 87 chain A radius 1.165 +atom 171 name D resname ASP resid 88 chain A radius 1.165 atom 172 name CA resname ASP resid 88 chain A radius 0.7 atom 173 name CA resname ILE resid 89 chain A radius 0.7 -atom 174 name I resname ILE resid 89 chain A radius 1.3839 +atom 174 name I resname ILE resid 89 chain A radius 1.3651 atom 175 name CA resname MET resid 90 chain A radius 0.7 atom 176 name M resname MET resid 90 chain A radius 1.5561 -atom 177 name C resname CYS resid 91 chain A radius 1.0004 +atom 177 name C resname CYS resid 91 chain A radius 1.0011 atom 178 name CA resname CYS resid 91 chain A radius 0.7 atom 179 name CA resname VAL resid 92 chain A radius 0.7 -atom 180 name V resname VAL resid 92 chain A radius 1.0877 +atom 180 name V resname VAL resid 92 chain A radius 1.0951 atom 181 name CA resname LYS resid 93 chain A radius 0.7 -atom 182 name K resname LYS resid 93 chain A radius 1.8244 -atom 183 name K resname LYS resid 94 chain A radius 1.6842 +atom 182 name K resname LYS resid 93 chain A radius 1.7005 +atom 183 name K resname LYS resid 94 chain A radius 1.7005 atom 184 name CA resname LYS resid 94 chain A radius 0.7 atom 185 name CA resname ILE resid 95 chain A radius 0.7 -atom 186 name I resname ILE resid 95 chain A radius 1.3492 -atom 187 name L resname LEU resid 96 chain A radius 1.27 +atom 186 name I resname ILE resid 95 chain A radius 1.3651 +atom 187 name L resname LEU resid 96 chain A radius 1.2668 atom 188 name CA resname LEU resid 96 chain A radius 0.7 -atom 189 name D resname ASP resid 97 chain A radius 1.163 +atom 189 name D resname ASP resid 97 chain A radius 1.165 atom 190 name CA resname ASP resid 97 chain A radius 0.7 -atom 191 name K resname LYS resid 98 chain A radius 1.6902 +atom 191 name K resname LYS resid 98 chain A radius 1.7005 atom 192 name CA resname LYS resid 98 chain A radius 0.7 atom 193 name V resname VAL resid 99 chain A radius 1.0951 atom 194 name CA resname VAL resid 99 chain A radius 0.7 atom 195 name CA resname GLY resid 100 chain A radius 0.7 -atom 196 name I resname ILE resid 101 chain A radius 1.4679 +atom 196 name I resname ILE resid 101 chain A radius 1.3651 atom 197 name CA resname ILE resid 101 chain A radius 0.7 atom 198 name CA resname ASN resid 102 chain A radius 0.7 -atom 199 name N resname ASN resid 102 chain A radius 1.1839 +atom 199 name N resname ASN resid 102 chain A radius 1.1832 atom 200 name CA resname TYR resid 103 chain A radius 0.7 -atom 201 name Y resname TYR resid 103 chain A radius 1.8748 -atom 202 name W resname TRP resid 104 chain A radius 2.0034 +atom 201 name Y resname TYR resid 103 chain A radius 1.8672 +atom 202 name W resname TRP resid 104 chain A radius 2.0068 atom 203 name CA resname TRP resid 104 chain A radius 0.7 -atom 204 name L resname LEU resid 105 chain A radius 1.2656 +atom 204 name L resname LEU resid 105 chain A radius 1.2668 atom 205 name CA resname LEU resid 105 chain A radius 0.7 atom 206 name CA resname ALA resid 106 chain A radius 0.7 atom 207 name A resname ALA resid 106 chain A radius 1.0 -atom 208 name H resname HIS resid 107 chain A radius 1.4455 +atom 208 name H resname HIS resid 107 chain A radius 1.4442 atom 209 name CA resname HIS resid 107 chain A radius 0.7 atom 210 name CA resname LYS resid 108 chain A radius 0.7 -atom 211 name K resname LYS resid 108 chain A radius 1.8328 +atom 211 name K resname LYS resid 108 chain A radius 1.7005 atom 212 name A resname ALA resid 109 chain A radius 1.0 atom 213 name CA resname ALA resid 109 chain A radius 0.7 -atom 214 name L resname LEU resid 110 chain A radius 1.2664 +atom 214 name L resname LEU resid 110 chain A radius 1.2668 atom 215 name CA resname LEU resid 110 chain A radius 0.7 -atom 216 name C resname CYS resid 111 chain A radius 1.0055 +atom 216 name C resname CYS resid 111 chain A radius 1.0011 atom 217 name CA resname CYS resid 111 chain A radius 0.7 atom 218 name CA resname SER resid 112 chain A radius 0.7 -atom 219 name S resname SER resid 112 chain A radius 0.7157 -atom 220 name E resname GLU resid 113 chain A radius 1.4369 +atom 219 name S resname SER resid 112 chain A radius 0.7151 +atom 220 name E resname GLU resid 113 chain A radius 1.3735 atom 221 name CA resname GLU resid 113 chain A radius 0.7 -atom 222 name K resname LYS resid 114 chain A radius 1.6925 +atom 222 name K resname LYS resid 114 chain A radius 1.7005 atom 223 name CA resname LYS resid 114 chain A radius 0.7 atom 224 name CA resname LEU resid 115 chain A radius 0.7 -atom 225 name L resname LEU resid 115 chain A radius 1.2631 +atom 225 name L resname LEU resid 115 chain A radius 1.2668 atom 226 name CA resname ASP resid 116 chain A radius 0.7 -atom 227 name D resname ASP resid 116 chain A radius 1.1689 +atom 227 name D resname ASP resid 116 chain A radius 1.165 atom 228 name CA resname GLN resid 117 chain A radius 0.7 -atom 229 name Q resname GLN resid 117 chain A radius 1.4498 -atom 230 name W resname TRP resid 118 chain A radius 2.0099 +atom 229 name Q resname GLN resid 117 chain A radius 1.4504 +atom 230 name W resname TRP resid 118 chain A radius 2.0068 atom 231 name CA resname TRP resid 118 chain A radius 0.7 -atom 232 name L resname LEU resid 119 chain A radius 1.2625 +atom 232 name L resname LEU resid 119 chain A radius 1.2668 atom 233 name CA resname LEU resid 119 chain A radius 0.7 atom 234 name C resname CYS resid 120 chain A radius 1.0011 atom 235 name CA resname CYS resid 120 chain A radius 0.7 atom 236 name CA resname GLU resid 121 chain A radius 0.7 -atom 237 name E resname GLU resid 121 chain A radius 1.0 +atom 237 name E resname GLU resid 121 chain A radius 1.3735 atom 238 name CA resname LYS resid 122 chain A radius 0.7 -atom 239 name K resname LYS resid 122 chain A radius 1.0 +atom 239 name K resname LYS resid 122 chain A radius 1.7005 atom 240 name c resname c resid 122 chain A radius 0.7 atom 241 name Ca resname Ca resid 201 chain A radius 1.0 bond 3:4 diff --git a/pyMBE.py b/pyMBE.py index 116e75d..ad446c1 100644 --- a/pyMBE.py +++ b/pyMBE.py @@ -52,9 +52,9 @@ def __init__(self, temperature=None, unit_length=None, unit_charge=None): self.setup_df() return - def activate_motion_of_rigid_object(self, name, espresso_system): + def enable_motion_of_rigid_object(self, name, espresso_system): ''' - Activates the motion of the rigid object `name` in the `espresso_system`. + Enables the motion of the rigid object `name` in the `espresso_system`. Args: name(`str`): Label of the object. @@ -63,7 +63,7 @@ def activate_motion_of_rigid_object(self, name, espresso_system): Note: - It requires that espressomd has the following features activated: ["VIRTUAL_SITES_RELATIVE", "MASS"]. ''' - print ('activate_motion_of_rigid_object requires that espressomd has the following features activated: ["VIRTUAL_SITES_RELATIVE", "MASS"]') + print ('enable_motion_of_rigid_object requires that espressomd has the following features activated: ["VIRTUAL_SITES_RELATIVE", "MASS"]') pmb_type = self.df.loc[self.df['name']==name].pmb_type.values[0] if pmb_type != 'protein': raise ValueError (f'The pmb_type: {pmb_type} is not currently supported. The supported pmb_type is: protein') @@ -416,7 +416,7 @@ def calculate_net_charge (self, espresso_system, molecule_name): pmb_type=self.df.loc[self.df['name']==molecule_name].pmb_type.values[0] if pmb_type not in valid_pmb_types: raise ValueError("The pyMBE object with name {molecule_name} has a pmb_type {pmb_type}. This function only supports pyMBE types {valid_pmb_types}") - charge_in_residues = {} + id_map = self.get_particle_id_map(object_name=molecule_name) def create_charge_map(espresso_system,id_map,label): charge_map={} @@ -1014,9 +1014,9 @@ def create_protein(self, name, number_of_proteins, espresso_system, topology_dic number_of_particles=1, position=[position], fix = True) - + index = self.df[self.df['particle_id']==particle_id[0]].index.values[0] - + self.add_value_to_df(key=('residue_id',''), index=int (index), new_value=residue_number) @@ -1189,7 +1189,7 @@ def create_variable_with_units(self, variable): return variable_with_units - def define_AA_particles_in_sequence(self, sequence): + def define_AA_particles_in_sequence(self, sequence, sigma_dict=None): ''' Defines in `pmb.df` all the different particles in `sequence`. @@ -1201,18 +1201,15 @@ def define_AA_particles_in_sequence(self, sequence): ''' already_defined_AA=[] - acidic_aminoacids = ['c','E','D','Y','C'] - basic_aminoacids = ['R','n','K','H'] - + for residue_name in sequence: if residue_name in already_defined_AA: continue - if residue_name in acidic_aminoacids: - self.define_particle (name=residue_name, acidity='acidic') - elif residue_name in basic_aminoacids: - self.define_particle (name=residue_name, acidity='basic') - else: - self.define_particle (name=residue_name, q=0) + self.define_particle (name=residue_name, q=0) + + if sigma_dict: + self.define_particles_parameter_from_dict(param_dict = sigma_dict, + param_name = 'sigma') return def define_AA_residues(self, sequence, model): @@ -1500,15 +1497,20 @@ def define_protein(self, name,model, topology_dict): if model == '2beadAA': self.define_particle(name='CA') + sigma_dict = {} + for residue in topology_dict.keys(): residue_name = self.re.split(r'\d+', residue)[0] + + if residue_name not in sigma_dict.keys(): + sigma_dict [residue_name] = topology_dict[residue]['sigma'] if residue_name != 'CA' and residue_name != 'Ca': protein_seq_list.append(residue_name) protein_sequence = ''.join(protein_seq_list) clean_sequence = self.protein_sequence_parser(sequence=protein_sequence) - self.define_AA_particles_in_sequence (sequence=clean_sequence) + self.define_AA_particles_in_sequence (sequence=clean_sequence, sigma_dict = sigma_dict) residue_list = self.define_AA_residues(sequence=clean_sequence, model=model) index = len(self.df) @@ -2295,8 +2297,9 @@ def read_protein_vtf_in_df (self,filename,unit_length=None): atom_name = line_split [3] atom_resname = line_split [5] chain_id = line_split [9] - - particles_dict [int(atom_id)] = [atom_name , atom_resname, chain_id] + radius = float(line_split [11])*unit_length + sigma = 2*radius + particles_dict [int(atom_id)] = [atom_name , atom_resname, chain_id, sigma] elif line_header.isnumeric (): @@ -2311,7 +2314,7 @@ def read_protein_vtf_in_df (self,filename,unit_length=None): if atom_id == 1: atom_name = particles_dict[atom_id][0] - numbered_name = [f'{atom_name}{i}',particles_dict[atom_id][2]] + numbered_name = [f'{atom_name}{i}',particles_dict[atom_id][2],particles_dict[atom_id][3]] numbered_label.append(numbered_name) elif atom_id != 1: @@ -2320,7 +2323,7 @@ def read_protein_vtf_in_df (self,filename,unit_length=None): i += 1 count = 1 atom_name = particles_dict[atom_id][0] - numbered_name = [f'{atom_name}{i}',particles_dict[atom_id][2]] + numbered_name = [f'{atom_name}{i}',particles_dict[atom_id][2],particles_dict[atom_id][3]] numbered_label.append(numbered_name) elif particles_dict[atom_id-1][1] == particles_dict[atom_id][1]: @@ -2328,14 +2331,16 @@ def read_protein_vtf_in_df (self,filename,unit_length=None): i +=1 count = 0 atom_name = particles_dict[atom_id][0] - numbered_name = [f'{atom_name}{i}',particles_dict[atom_id][2]] + numbered_name = [f'{atom_name}{i}',particles_dict[atom_id][2],particles_dict[atom_id][3]] numbered_label.append(numbered_name) count +=1 topology_dict = {} for i in range (0, len(numbered_label)): - topology_dict [numbered_label[i][0]] = {'initial_pos': coord_list[i] ,'chain_id':numbered_label[i][1] } + topology_dict [numbered_label[i][0]] = {'initial_pos': coord_list[i] , + 'chain_id':numbered_label[i][1], + 'sigma':numbered_label[i][2] } return topology_dict diff --git a/samples/Beyer2024/create_paper_data.py b/samples/Beyer2024/create_paper_data.py index b3127fb..c45cbc8 100644 --- a/samples/Beyer2024/create_paper_data.py +++ b/samples/Beyer2024/create_paper_data.py @@ -3,14 +3,13 @@ from lib import analysis import os import numpy as np -import pandas as pd import argparse import subprocess # Create an instance of pyMBE library pmb = pyMBE.pymbe_library() -valid_fig_labels=["7a", "7b", "7c", "9"] +valid_fig_labels=["7a", "7b", "7c", "8a", "8b", "9"] valid_modes=["short-run","long-run", "test"] parser = argparse.ArgumentParser(description='Script to create the data from Beyer2024') @@ -57,6 +56,35 @@ subprocess.check_output(run_command) + +## Protein plots (Fig. 8) + +labels_fig8=["8a", "8b"] +if fig_label in labels_fig8: + + script_path=pmb.get_resource(f"samples/Beyer2024/globular_protein.py") + pH_range = np.linspace(2, 7, num=11) + + if fig_label == "8a": + protein_pdb = "1f6s" + path_to_cg = f"parameters/globular_proteins/{protein_pdb}.vtf" + for pH in pH_range: + + run_command=["python3", script_path, "--pdb", protein_pdb, "--pH", str(pH), "--path_to_cg", path_to_cg, "--mode", mode, "--no_verbose", "--metal_ion_name", "Ca", "--metal_ion_charge", str(2)] + print(subprocess.list2cmdline(run_command)) + subprocess.check_output(run_command) + + elif fig_label == "8b": + protein_pdb = "1beb" + path_to_cg = f"parameters/globular_proteins/{protein_pdb}.vtf" + for pH in pH_range: + run_command=["python3", script_path, "--pdb", protein_pdb, "--pH", str(pH), "--path_to_cg", path_to_cg, "--mode", mode, "--no_verbose"] + print(subprocess.list2cmdline(run_command)) + subprocess.check_output(run_command) + else: + raise RuntimeError() + + ## Weak polyelectrolyte dialysis plot (Fig. 9) if fig_label == "9" and not plot: script_path=pmb.get_resource(f"samples/Beyer2024/weak_polyelectrolyte_dialysis.py") @@ -70,6 +98,10 @@ # Analyze all time series if fig_label in labels_fig7: time_series_folder_path=pmb.get_resource(f"samples/Beyer2024/time_series/peptides") + +if fig_label in labels_fig8: + time_series_folder_path=pmb.get_resource(f"samples/Beyer2024/time_series/globular_protein") + if fig_label == "9": time_series_folder_path=pmb.get_resource(f"samples/Beyer2024/time_series/grxmc") @@ -104,7 +136,7 @@ linewidth=0.6) # Set labels for the axes - if fig_label in labels_fig7: + if fig_label in labels_fig7+labels_fig8: plt.ylabel(r"Net charge $Z/e$") plt.xlabel(r"pH in the solution") elif fig_label == "9": @@ -117,7 +149,7 @@ if fig_label in ["7a","7b"]: pka_path=pmb.get_resource("parameters/pka_sets/CRC1991.txt") pmb.load_pka_set (filename=pka_path) - elif fig_label == "7c": + elif fig_label in ["7c", "8a", "8b"]: pka_path=pmb.get_resource("parameters/pka_sets/Nozaki1967.txt") pmb.load_pka_set (filename=pka_path) # FIXME: this is only necessary due to an undesired feature in calculate_HH @@ -132,6 +164,10 @@ ref_path=pmb.get_resource("testsuite/data/Lunkad2021b.csv") elif fig_label == "7c": ref_path=pmb.get_resource("testsuite/data/Blanco2020a.csv") + elif fig_label == "8a": + ref_path=pmb.get_resource("testsuite/data/Torres2022.csv") + elif fig_label == "8b": + ref_path=pmb.get_resource("testsuite/data/Torres2017.csv") elif fig_label == "9": ref_path=pmb.get_resource("testsuite/data/Landsgesell2020a.csv") else: @@ -155,6 +191,32 @@ label=r"HH", color="black") + elif fig_label in labels_fig8: + + if fig_label == "8a": + protein_pdb = '1f6s' + elif fig_label == "8b": + protein_pdb = '1beb' + + path_to_cg=pmb.get_resource(f"parameters/globular_proteins/{protein_pdb}.vtf") + topology_dict = pmb.read_protein_vtf_in_df (filename=path_to_cg) + + pmb.define_protein (name=protein_pdb, + topology_dict=topology_dict, + model = '2beadAA') + + pH_range_HH = np.linspace(2, 7, num=1000) + + Z_HH = pmb.calculate_HH(molecule_name=protein_pdb, + pH_list=pH_range_HH) + + # Plot HH + plt.plot(pH_range_HH, + Z_HH, + label=r"HH", + color="black") + + elif fig_label == "9": c_salt_res = 0.01 * pmb.units.mol/pmb.units.L pmb.define_particle(name='A', acidity='acidic', sigma=1*pmb.units('reduced_length'), epsilon=1*pmb.units('reduced_energy'), pka=4.0) @@ -186,6 +248,7 @@ # Plot Ref data ref_data=ref_data.sort_values(by="pH",ascending=True) + if fig_label in ["7a","7b"]: style={"linestyle":"none", "marker":"s", @@ -197,6 +260,16 @@ "label":"Blanco et al.", "color":"green", "markeredgewidth":1.5} + + elif fig_label in labels_fig8: + + style={"linestyle":"none", + "marker":"s", + "label":"Torres et al.", + "color":"C0", + "markeredgewidth":1.5} + + elif fig_label == "9": style={"linestyle":"none", "marker":"s", @@ -204,11 +277,12 @@ "color":"C0", "markeredgewidth":1.5} - if fig_label in ["7a", "7b", "7c"]: + if fig_label in labels_fig7+labels_fig8: plt.errorbar(ref_data["pH"], ref_data["charge"], ref_data["charge_error"], **style) + elif fig_label == "9": ref_data = ref_data.loc[np.isclose(ref_data["cs_bulk"], (c_salt_res.to('mol/reduced_length**3')*pmb.N_A).magnitude, rtol=1e-03) & np.isclose(ref_data["c_poly_[mol/l]"], 0.435/50, rtol=1e-03) & np.isclose(ref_data["Kcideal_in_mol_per_l"], 10**(-4), rtol=1e-03)] plt.errorbar(ref_data["pH"], @@ -231,6 +305,24 @@ fillstyle="none", markeredgewidth=1.5) plt.xticks([2,4,6,8,10,12]) + + elif fig_label in labels_fig8: + + data=data.astype({("pH","value"): 'float'}).sort_values(by=("pH","value")) + data=data[data.pdb.value == f'{protein_pdb}'] + + + plt.errorbar(data["pH"]["value"], + data["mean","charge"], + yerr=data["err_mean","charge"], + linestyle="none", + marker="o", + label="pyMBE", + color="C1", + fillstyle="none", + markeredgewidth=1.5) + plt.xticks([2,3,4,5,6,7]) + elif fig_label == "9": data=data.astype({("pH","value"): 'float'}).sort_values(by=("pH","value")) plt.errorbar(data["pH"]["value"], @@ -244,7 +336,6 @@ markeredgewidth=1.5) plt.xticks([2,4,6,8,10,12]) - # Save plot fig_path=pmb.get_resource("samples/Beyer2024")+"/figs" if not os.path.exists(fig_path): diff --git a/samples/Beyer2024/globular_protein.py b/samples/Beyer2024/globular_protein.py index 8548d31..6f81e8b 100644 --- a/samples/Beyer2024/globular_protein.py +++ b/samples/Beyer2024/globular_protein.py @@ -1,13 +1,8 @@ import os -import sys -import inspect from tqdm import tqdm import espressomd import argparse - -from espressomd import interactions -from espressomd.io.writer import vtf -from espressomd import electrostatics +import pandas as pd # Create an instance of pyMBE library import pyMBE @@ -17,35 +12,72 @@ from lib.handy_functions import setup_electrostatic_interactions from lib.handy_functions import minimize_espresso_system_energy from lib.handy_functions import setup_langevin_dynamics - +from lib import analysis # Here you can adjust the width of the panda columns displayed when running the code pmb.pd.options.display.max_colwidth = 10 #This line allows you to see the complete amount of rows in the dataframe pmb.pd.set_option('display.max_rows', None) -# The trajectories of the simulations will be stored using espresso built-up functions in separed files in the folder 'frames' -if not os.path.exists('./frames'): - os.makedirs('./frames') +valid_modes=["short-run","long-run", "test"] parser = argparse.ArgumentParser(description='Script to run globular protein simulation in espressomd') -parser.add_argument('--pdb', type=str, required= True, help='PDB code of the protein') -parser.add_argument('--pH', type=float, required= True, help='pH value') -parser.add_argument('--path_to_cg', type=str, required= True, help='Path to the CG structure of the protein') -parser.add_argument('--move_protein', type=float, required= False, default=False, help='Activates the motion of the protein') -parser.add_argument('--metal_ion_name', type=str, required= False, default=None, help='Name of the metal ion in the protein') -parser.add_argument('--metal_ion_charge', type=int, required= False, default=None, help='Charge of the metal ion in the protein') +parser.add_argument('--pdb', + type=str, + required= True, + help='PDB code of the protein') +parser.add_argument('--pH', + type=float, + required= True, + help='pH value') +parser.add_argument('--path_to_cg', + type=str, + required= True, + help='Path to the CG structure of the protein') +parser.add_argument('--move_protein', + type=float, + required= False, + default=False, + help='Activates the motion of the protein') +parser.add_argument('--metal_ion_name', + type=str, + required= False, + default=None, + help='Name of the metal ion in the protein') +parser.add_argument('--metal_ion_charge', + type=int, + required= False, + default=None, + help='Charge of the metal ion in the protein') + +parser.add_argument('--mode', + type=str, + default= "short-run", + help='sets for how long the simulation runs, valid modes are {valid_modes}') + +parser.add_argument('--output', + type=str, + required= False, + help='output directory') + +parser.add_argument('--no_verbose', action='store_false', help="Switch to deactivate verbose") args = parser.parse_args () + +mode=args.mode +verbose=args.no_verbose + protein_name = args.pdb +pH_value = args.pH -#System Parameters -pmb.set_reduced_units(unit_length=0.4*pmb.units.nm) +inputs={"pH": args.pH, + "protein_pdb": args.pdb} +#System Parameters SEED = 77 -pH_value = args.pH + c_salt = 0.01 * pmb.units.mol / pmb.units.L c_protein = 2e-4 * pmb.units.mol / pmb.units.L Box_V = 1. / (pmb.N_A*c_protein) @@ -54,17 +86,38 @@ epsilon = 1*pmb.units('reduced_energy') #Simulation Parameters -t_max = 1e3 # in LJ units of time -stride_obs = 10 # in LJ units of time -stride_traj = 100 # in LJ units of time + # in LJ units of time dt = 0.01 -N_samples = int (t_max / stride_obs) -integ_steps = int (stride_obs/dt) +stride_traj = 100 # in LJ units of time + +if mode == 'short-run': + stride_obs = 10 # in LJ units of time + integ_steps = int (stride_obs/dt) + t_max = 5e3 + N_samples = int (t_max / stride_obs) + +elif mode == 'long-run': + stride_obs = 10 # in LJ units of time + integ_steps = int (stride_obs/dt) + t_max = 1e5 + N_samples = int (t_max / stride_obs) + +elif mode == 'test': + t_max = 1e3 + stride_obs = 10 # in LJ units of time + integ_steps = int (stride_obs/dt) + N_samples = int (t_max / stride_obs) +else: + raise RuntimeError() #Switch for Electrostatics and WCA interactions WCA = True Electrostatics = True +# The trajectories of the simulations will be stored using espresso built-up functions in separed files in the folder 'frames' +if not os.path.exists('./frames'): + os.makedirs('./frames') + espresso_system = espressomd.System(box_l=[Box_L.to('reduced_length').magnitude] * 3) espresso_system.virtual_sites = espressomd.virtual_sites.VirtualSitesRelative() @@ -78,21 +131,15 @@ clean_sequence = pmb.df.loc[pmb.df['name']== protein_name].sequence.values[0] epsilon_dict = {} -sigma_dict = {} for residue in clean_sequence: if residue not in epsilon_dict.keys(): epsilon_dict [residue] = epsilon - sigma_dict [residue] = 0.355*pmb.units.nm epsilon_dict ['CA'] = epsilon - sigma_dict ['CA'] = 0.355*pmb.units.nm - -#Define epsilon and sigma for each particle into pmb.df +#Define epsilon for each particle into pmb.df pmb.define_particles_parameter_from_dict (param_dict = epsilon_dict, param_name ='epsilon') -pmb.define_particles_parameter_from_dict (param_dict = sigma_dict, - param_name ='sigma') #Defines the metal ion present in the protein if args.metal_ion_name is not None: @@ -105,8 +152,8 @@ cation_name = 'Na' anion_name = 'Cl' -pmb.define_particle(name = cation_name, q = 1, sigma=0.2*pmb.units.nm, epsilon=epsilon) -pmb.define_particle(name = anion_name, q =-1, sigma=0.2*pmb.units.nm, epsilon=epsilon) +pmb.define_particle(name = cation_name, q = 1, sigma=0.4*pmb.units.nm, epsilon=epsilon) +pmb.define_particle(name = anion_name, q =-1, sigma=0.4*pmb.units.nm, epsilon=epsilon) # Here we upload the pka set from the reference_parameters folder path_to_pka=pmb.get_resource('parameters/pka_sets/Nozaki1967.txt') @@ -117,10 +164,9 @@ number_of_proteins=1, espresso_system=espresso_system, topology_dict=topology_dict) - #Here we activate the motion of the protein if args.move_protein: - pmb.activate_motion_of_rigid_object(espresso_system=espresso_system, + pmb.enable_motion_of_rigid_object(espresso_system=espresso_system, name=protein_name) # Here we put the protein on the center of the simulation box @@ -145,15 +191,17 @@ list_ionisible_groups = basic_groups + acidic_groups total_ionisible_groups = len (list_ionisible_groups) -print('The box length of the system is', Box_L.to('reduced_length'), Box_L.to('nm')) -print('The ionisable groups in the protein are ', list_ionisible_groups) -print ('The total amount of ionizable groups are:',total_ionisible_groups) +if verbose: + print('The box length of the system is', Box_L.to('reduced_length'), Box_L.to('nm')) + print('The ionisable groups in the protein are ', list_ionisible_groups) + print ('The total amount of ionizable groups are:',total_ionisible_groups) #Setup of the reactions in espresso RE, sucessfull_reactions_labels = pmb.setup_cpH(counter_ion=cation_name, constant_pH= pH_value, SEED = SEED ) -print('The acid-base reaction has been sucessfully setup for ', sucessfull_reactions_labels) +if verbose: + print('The acid-base reaction has been sucessfully setup for ', sucessfull_reactions_labels) type_map = pmb.get_type_map() types = list (type_map.values()) @@ -162,14 +210,12 @@ # Setup the non-interacting type for speeding up the sampling of the reactions non_interacting_type = max(type_map.values())+1 RE.set_non_interacting_type (type=non_interacting_type) -print('The non interacting type is set to ', non_interacting_type) +if verbose: + print('The non interacting type is set to ', non_interacting_type) # Setup the potential energy if (WCA): - - print ('Setup of LJ interactions.. ') - pmb.setup_lj_interactions (espresso_system=espresso_system) minimize_espresso_system_energy (espresso_system=espresso_system) @@ -191,7 +237,7 @@ observables_df = pmb.pd.DataFrame() time_step = [] net_charge_list = [] -net_charge_amino_save = {} + Z_sim=[] particle_id_list = pmb.df.loc[~pmb.df['molecule_id'].isna()].particle_id.dropna().to_list() @@ -201,34 +247,72 @@ #Here we start the main loop over the Nsamples -for step in tqdm(range(N_samples)): - - espresso_system.integrator.run (steps = integ_steps) - RE.reaction( reaction_steps = total_ionisible_groups) +labels_obs=["time","charge"] +time_series={} - charge_dict=pmb.calculate_net_charge (espresso_system=espresso_system, - molecule_name=protein_name) - net_charge = charge_dict['mean'] - net_charge_residues = charge_dict ['residues'] +for label in labels_obs: + time_series[label]=[] - time_step.append (str(espresso_system.time)) - net_charge_list.append (net_charge) - - if len(net_charge_amino_save.keys()) == 0: - for amino in net_charge_residues.keys(): - net_charge_amino_save [amino] = [] - for amino in net_charge_residues.keys(): - net_charge_amino_save [amino].append (net_charge_residues[amino]) - - if (step % stride_traj == 0 ): - n_frame +=1 - pmb.write_output_vtf_file(espresso_system=espresso_system, - filename=f"frames/trajectory{n_frame}.vtf") +charge_dict=pmb.calculate_net_charge (espresso_system=espresso_system, + molecule_name=protein_name) + +net_charge_residues = charge_dict ['residues'] +net_charge_amino_save = {} +AA_label_list=[] +for amino in net_charge_residues.keys(): + amino_part_row=pmb.df[(pmb.df['residue_id']== amino) & (pmb.df['acidity'] != "inert")] + if not amino_part_row.empty: + label = f'charge_{amino_part_row["name"].values[0]}' + if label not in AA_label_list: + AA_label_list.append(label) + net_charge_amino_save[label] = [] + time_series[label] = [] + +for step in tqdm(range(N_samples)): + espresso_system.integrator.run (steps = integ_steps) + RE.reaction( reaction_steps = total_ionisible_groups) + charge_dict=pmb.calculate_net_charge (espresso_system=espresso_system, + molecule_name=protein_name) + charge_residues = charge_dict['residues'] + charge_residues_per_type={} + + for label in AA_label_list: + charge_residues_per_type[label]=[] + + for amino in charge_residues.keys(): + amino_part_row=pmb.df[(pmb.df['residue_id']== amino) & (pmb.df['acidity'] != "inert")] + if not amino_part_row.empty: + label = f'charge_{amino_part_row["name"].values[0]}' + if label in AA_label_list: + charge_residues_per_type[label].append(charge_residues[amino]) + + if (step % stride_traj == 0 ): + n_frame +=1 + pmb.write_output_vtf_file(espresso_system=espresso_system, + filename=f"frames/trajectory{n_frame}.vtf") + + # Store observables + time_series["time"].append(espresso_system.time) + time_series["charge"].append(charge_dict["mean"]) + + for label in AA_label_list: + charge_amino = pmb.np.mean(charge_residues_per_type[label]) + time_series[label].append(charge_amino) + +data_path = args.output +if data_path is None: + data_path=pmb.get_resource(path="samples/Beyer2024/")+"/time_series/globular_protein" + +if not os.path.exists(data_path): + os.makedirs(data_path) + +time_series=pd.DataFrame(time_series) +filename=analysis.built_output_name(input_dict=inputs) + +time_series.to_csv(f"{data_path}/{filename}_time_series.csv", index=False) + +if verbose: + print("*** DONE ***") -#We save the calculated observables into a new df -observables_df['time'] = time_step -observables_df['Znet'] = net_charge_list -observables_df=pmb.pd.concat([observables_df,pmb.pd.DataFrame(net_charge_amino_save)], axis=1) -observables_df.to_csv(f'pH-{pH_value}_observables.csv',index=False) diff --git a/samples/Beyer2024/run_test_protein.py b/samples/Beyer2024/run_test_protein.py deleted file mode 100644 index 24e5c9c..0000000 --- a/samples/Beyer2024/run_test_protein.py +++ /dev/null @@ -1,180 +0,0 @@ -from matplotlib import colors -from matplotlib.axis import YAxis -import numpy as np -import pandas as pd -import matplotlib.pyplot as plt -from pathlib import Path -import argparse -from matplotlib.ticker import FormatStrFormatter -from matplotlib.ticker import StrMethodFormatter - -import os -import sys -import inspect - -# Create an instance of pyMBE library -import pyMBE -pmb = pyMBE.pymbe_library() - -parser = argparse.ArgumentParser(description='Script to reproduce the numerical data for globular proteins from Torres') -parser.add_argument('--run_command', type=str, required= True, help='Run command for globular_protein.py') -parser.add_argument('--pdb_code', type=str, required= True, help='PDB code of the protein') -args = parser.parse_args () - -pdb=args.pdb_code - -#Run the main script for each pH value -for pH_value in np.arange(2.0, 7.5, 0.5): - print (f'{args.run_command} --pH {pH_value}') - os.system(f'{args.run_command} --pH {pH_value}') - - -if not os.path.exists(f'{pyMBE_path}/tests/observables_results'): - os.system(f'mkdir {pyMBE_path}/tests/observables_results') - -os.system(f'mv pH*.csv {pyMBE_path}/tests/observables_results') -os.system(f'python3 {pyMBE_path}/handy_scripts/data_analysis.py {pyMBE_path}/tests/observables_results/') - -# Here you can adjust the width of the panda columns displayed when running the code -pmb.pd.options.display.max_colwidth = 10 - -#Load the pmb.df -pmb.df = pmb.read_pmb_df(filename='df.csv') -protein_sequence = pmb.df.loc[pmb.df['name']== pdb].sequence.values[0] -titratables_AA_df = pmb.df[['name','pka','acidity']].drop_duplicates().dropna() - -# Get the pka_set -pka_set = {} -for index in titratables_AA_df.name.keys(): - name = titratables_AA_df.name[index] - pka_value = titratables_AA_df.pka[index] - acidity = titratables_AA_df.acidity[index] - pka_set[name] = {'pka_value':pka_value,'acidity':acidity} - -# Calculate Henderson-Hasselbach titration curve -pH_range = np.linspace(2, 7, num=31) -Z_HH = pmb.calculate_HH (molecule_name=pdb, - pH_list = pH_range, - pka_set=pka_set ) - -# Here we have to add +2 for the Calcium in the protein charge by HH -if pdb == '1f6s': - for index in range (len (Z_HH)): - Z_HH[index] = Z_HH[index] +2 - -# Read the reference data from Torres2022 - -ref_data_torres = f'{pyMBE_path}/reference_data/{pdb}-10mM-torres.dat' -pH_list = [] -znet_ref = [] -sigma_ref = [] - -with open (ref_data_torres,'r') as file: - for line in file: - line_split = line.split () - pH = float (line_split[0]) - pH_list.append(pH) - znet_ref.append (float(line_split[1])) - sigma_ref.append(float(line_split[2])) - -# Read the results from espresso simulation using pyMBE -espresso_data = 'analyzed_observables.csv' -full_data = pd.read_csv(espresso_data) -columns = full_data.columns.to_list() -full_data.sort_values('pH',ascending=True, inplace=True) - -znet_espresso = full_data['Znet'].to_list() - -numerical_comparison = pd.DataFrame() -numerical_comparison['pH'] = pH_list -numerical_comparison['ref_torres'] = znet_ref -numerical_comparison['espresso'] = znet_espresso - -numerical_comparison['error %'] = abs(( (numerical_comparison['espresso']) - (numerical_comparison['ref_torres'])) / (numerical_comparison['ref_torres'])) *100 - -#Save `numerical_comparison` to a csv file - -path_to_tests=pmb.get_resource("tests") -numerical_comparison.to_csv(f'{path_to_tests}/{pdb}-numerical_comparison.csv',index = True) - -#Plot results - -fig = plt.figure(figsize = (20,20)) -ax1 = fig.add_subplot (111) - -# Plots the HH equation -ax1.plot( - pH_range, - Z_HH, - linewidth = 3, - color = 'black', - label = 'HH' - ) - -# Plot the ref data from Torres2022 -ax1.errorbar ( - pH_list, - znet_ref, - yerr=sigma_ref, - linewidth = 2, - elinewidth = 3, - marker = 'o', - markersize = 10, - markerfacecolor = 'none', - alpha = 0.8, #changes the line opacity - color = 'red', - label = 'Ref Torres et al.') - -#Plots the resuls from espresso - -ax1.errorbar ( - full_data['pH'], - full_data['Znet'], - yerr = full_data['ZnetErr'], - linewidth = 2, - elinewidth = 3, - marker = 's', - markersize = 10, - markerfacecolor = 'none', - alpha = 0.8, #changes the line opacity - color = 'blue', - label = 'ESPResSo') - -# Add axes information -ax1.set_title ('Net charge vs pH. $c_{salt}$ = 0.01 M',fontsize ='40',pad = 30) -ax1.set_xlabel('$\it{pH}$',size = 45) -ax1.set_ylabel('$\it{Z}$', size = 45) - -ax1.hlines(y=0,xmin=2,xmax=7,lw = 3, colors='grey',linestyles='dashed') - -ax1.invert_yaxis () -ax1.set_xlim ([2.0,7.0]) -ax1.set_ylim ([-10.0,20.0]) - -y = np.linspace(-10,20,7) -minor_ticks = np.linspace(-10,20,31) - -ax1.set_xticks(pH_list, minor=True) -ax1.set_yticks (y,minor=True) -ax1.set_yticks (minor_ticks,minor=True) - -ax1.tick_params(axis='x',which='major',length=30,direction='in',width=3,colors='black',pad=15,labelsize=40) -ax1.tick_params(axis='x',which='minor',length=15,direction='in',width=3) - -ax1.tick_params(axis='y',which='major',length=30,direction='in',width=3,colors='black',pad=10,labelsize=40) -ax1.tick_params(axis='y',which='minor',length=15,direction='in',width=3,colors='black') - -ax1.spines['left'].set_color('black') -ax1.spines['left'].set_lw(3) -ax1.spines['top'].set_lw(3) -ax1.spines['right'].set_lw(3) -ax1.spines['bottom'].set_lw(3) - -ax1.legend(frameon =False) - -plt.legend(prop={'size': 35}) -pdf_name = f'{path_to_tests}/observables_results/{pdb}-analyzed_observables.pdf' -plt.savefig(pdf_name) -plt.show() - - diff --git a/testsuite/cph_ideal_tests.py b/testsuite/cph_ideal_tests.py index 9148858..ba66500 100644 --- a/testsuite/cph_ideal_tests.py +++ b/testsuite/cph_ideal_tests.py @@ -21,6 +21,6 @@ data = pd.read_csv(data_path) # Check if charges agree -np.testing.assert_allclose(data["Z_sim"], data["Z_HH"], rtol=0.05, atol=0.1) +np.testing.assert_allclose(data["Z_sim"], data["Z_HH"], rtol=0.15, atol=0.2) print(f"*** Test passed ***\n") diff --git a/testsuite/data/Torres2017.csv b/testsuite/data/Torres2017.csv new file mode 100644 index 0000000..b6552fc --- /dev/null +++ b/testsuite/data/Torres2017.csv @@ -0,0 +1,12 @@ +pH,charge,charge_error +2.0,16.4270802,1.46008074 +2.5,13.3768396,1.60224831 +3.0,10.0348797,1.62584019 +3.5,6.69452,1.62617445 +4.0,3.50406003,1.62130284 +4.5,0.505540013,1.56549335 +5.0,-2.13657999,1.43019104 +5.5,-4.10567999,1.17734969 +6.0,-5.3159399,0.869300783 +6.5,-6.00544024,0.698061168 +7.0,-6.57043982,0.735363901 diff --git a/testsuite/data/Torres2022.csv b/testsuite/data/Torres2022.csv new file mode 100644 index 0000000..ecc5bfd --- /dev/null +++ b/testsuite/data/Torres2022.csv @@ -0,0 +1,12 @@ +pH,charge,charge_error +2.0,13.4952602,1.39311898 +2.5,11.0979605,1.48351896 +3.0,8.50181961,1.50077295 +3.5,5.94800997,1.46223402 +4.0,3.62516999,1.37238944 +4.5,1.62161994,1.24127698 +5.0,0.0511300564,1.09670246 +5.5,-1.15866995,0.95182687 +6.0,-2.11468983,0.888424993 +6.5,-3.02019978,0.890221238 +7.0,-3.89163017,0.819014013 diff --git a/testsuite/globular_protein_tests.py b/testsuite/globular_protein_tests.py new file mode 100644 index 0000000..0f5bd20 --- /dev/null +++ b/testsuite/globular_protein_tests.py @@ -0,0 +1,80 @@ +# Import pyMBE and other libraries +import pyMBE +from lib import analysis +import tempfile +import subprocess +import numpy as np +import pandas as pd + +# Template of the test + +def run_protein_test(script_path, test_pH_values, protein_pdb, rtol, atol,mode="test"): + """ + Runs a set of tests for a given protein pdb. + + Args: + script_path(`str`): Path to the script to run the test. + test_pH_values(`lst`): List of pH values to be tested. + protein_pdb(`str`): PDB code of the protein. + """ + valid_modes=["test","save"] + assert mode in valid_modes, f"Mode {mode} not supported, valid modes: {valid_modes}" + + print(f"Running tests for {protein_pdb}") + with tempfile.TemporaryDirectory() as time_series_path: + + for pH in test_pH_values: + print(f"pH = {pH}") + + if protein_pdb == '1f6s': + run_command=["python3", script_path, "--pdb", protein_pdb, "--pH", str(pH), "--path_to_cg", f"parameters/globular_proteins/{protein_pdb}.vtf", "--metal_ion_name","Ca", "--metal_ion_charge", "2","--mode", "test", "--no_verbose", "--output", time_series_path] + + else: + run_command=["python3", script_path, "--pdb", protein_pdb, "--pH", str(pH), "--path_to_cg", f"parameters/globular_proteins/{protein_pdb}.vtf", "--mode", "test", "--no_verbose", "--output", time_series_path] + + + print(subprocess.list2cmdline(run_command)) + subprocess.check_output(run_command) + # Analyze all time series + data=analysis.analyze_time_series(path_to_datafolder=time_series_path) + + data_path=pmb.get_resource(path="testsuite/globular_protein_tests_data") + + if mode == "test": + # Get reference test data + ref_data=pd.read_csv(data_path+f"/{protein_pdb}.csv", header=[0, 1]) + # Check charge + test_charge=np.sort(data["mean","charge"].to_numpy()) + ref_charge=np.sort(ref_data["mean","charge"].to_numpy()) + np.testing.assert_allclose(test_charge, ref_charge, rtol=rtol, atol=atol) + print(f"Test for {protein_pdb} was successful") + + elif mode == "save": + # Save data for future testing + data.to_csv(f"{data_path}/{protein_pdb}.csv", index=False) + else: + raise RuntimeError + +# Create an instance of pyMBE library +pmb = pyMBE.pymbe_library() + +script_path=pmb.get_resource(f"samples/Beyer2024/globular_protein.py") +test_pH_values=[2,5,7] +rtol=0.1 # relative tolerance +atol=0.5 # absolute tolerance + +# Run test for 1BEB case +protein_pdb = "1beb" +run_protein_test(script_path=script_path, + test_pH_values=test_pH_values, + protein_pdb=protein_pdb, + rtol=rtol, + atol=atol) + +# Run test for 1F6S case +protein_pdb = "1f6s" +run_protein_test(script_path=script_path, + test_pH_values=test_pH_values, + protein_pdb=protein_pdb, + rtol=rtol, + atol=atol) diff --git a/testsuite/globular_protein_tests_data/1beb.csv b/testsuite/globular_protein_tests_data/1beb.csv new file mode 100644 index 0000000..84fc90e --- /dev/null +++ b/testsuite/globular_protein_tests_data/1beb.csv @@ -0,0 +1,5 @@ +,pH,protein,pdb,n_blocks,block_size,mean,mean,mean,mean,mean,mean,mean,mean,mean,mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int +,value,value,value,nan,nan,charge,charge_E,charge_K,charge_D,charge_C,charge_H,charge_Y,charge_c,charge_R,charge_n,charge,charge_E,charge_K,charge_D,charge_C,charge_H,charge_Y,charge_c,charge_R,charge_n,charge,charge_E,charge_K,charge_D,charge_C,charge_H,charge_Y,charge_c,charge_R,charge_n,charge,charge_E,charge_K,charge_D,charge_C,charge_H,charge_Y,charge_c,charge_R,charge_n +0,2,protein,1beb,16.0,5.625,14.822222222222223,-0.10208333333333333,1.0,-0.3222222222222222,0.0,1.0,0.0,-0.32222222222222224,1.0,1.0,0.21111111111111105,0.009297195145696388,0.0,0.014715302356961274,0.0,0.0,0.0,0.03860211725786713,0.0,0.0,43.65401973295158,49.20281059513185,,59.96011307221751,,,,148.20848421660168,,,10.308329055432326,9.145819000106554,,7.504989182685652,,,,3.036263425661524,, +1,5,protein,1beb,16.0,5.625,-2.5555555555555554,-0.7652777777777777,1.0,-0.9455555555555557,0.0,1.0,0.0,-0.8555555555555555,1.0,1.0,0.20712911223631136,0.016393449224282722,0.0,0.013654918166120838,0.0,0.0,0.0,0.04541985207993266,0.0,0.0,38.818703463064196,26.885480844316678,,30.32435701813835,,,,60.577330401629915,,,11.59235007495224,16.737658612296176,,14.839556193407033,,,,7.428521478514892,, +2,7,protein,1beb,16.0,5.625,-7.544444444444444,-0.9965277777777778,0.9985185185185186,-0.9988888888888889,0.0,0.5777777777777777,0.0,-1.0,1.0,0.8333333333333334,0.10592333589167101,0.0016652192789280268,0.0017213259316477447,0.0012909944487357998,0.0,0.06936884774188654,0.0,0.0,0.0,0.04718953116795983,44.386226064250636,74.74352711284816,32.95880149812729,66.66666666666724,,51.26553132425145,,,,63.07084958770352,10.138280270735565,6.0205882352887725,13.653409090897004,6.749999999993956,,8.777827682178453,,,,7.134833333327006 diff --git a/testsuite/globular_protein_tests_data/1f6s.csv b/testsuite/globular_protein_tests_data/1f6s.csv new file mode 100644 index 0000000..692d028 --- /dev/null +++ b/testsuite/globular_protein_tests_data/1f6s.csv @@ -0,0 +1,5 @@ +,pH,protein,pdb,n_blocks,block_size,mean,mean,mean,mean,mean,mean,mean,mean,mean,mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,err_mean,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,n_eff,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int,tau_int +,value,value,value,nan,nan,charge,charge_E,charge_K,charge_D,charge_C,charge_H,charge_Y,charge_n,charge_R,charge_c,charge,charge_E,charge_K,charge_D,charge_C,charge_H,charge_Y,charge_n,charge_R,charge_c,charge,charge_E,charge_K,charge_D,charge_C,charge_H,charge_Y,charge_n,charge_R,charge_c,charge,charge_E,charge_K,charge_D,charge_C,charge_H,charge_Y,charge_n,charge_R,charge_c +0,2,protein,1f6s,16.0,5.625,13.655555555555555,-0.04920634920634919,1.0,-0.32820512820512815,0.0,1.0,0.0,1.0,1.0,-0.7333333333333333,0.21185177091425547,0.010086236877608117,0.0,0.017151825329504444,0.0,0.0,0.0,0.0,0.0,0.031091263510296056,38.13371029911677,68.3465524450081,,33.80914528786571,,,,,,204.5718713676868,11.80058264642592,6.584092158293755,,13.310008169922538,,,,,,2.19971590908891 +1,5,protein,1f6s,16.0,5.625,-0.03333333333333333,-0.8428571428571429,1.0,-0.9290598290598292,0.0,0.9814814814814814,0.0,1.0,1.0,-1.0,0.15785209517335297,0.01785978816385423,0.0,0.007831480796139175,0.0,0.009755234956345135,0.0,0.0,0.0,0.0,40.087692000220464,40.329623515629144,,61.19870038579567,,61.94959003947759,,,,,11.225390576168023,11.15805109921768,,7.353097323355037,,7.263970588228863,,,, +2,7,protein,1f6s,16.0,5.625,-4.333333333333333,-0.9984126984126984,1.0,-0.9965811965811966,0.0,0.20740740740740743,-0.002777777777777778,1.0,1.0,-1.0,0.1154219312878719,0.001536898153256906,0.0,0.0019746179576321165,0.0,0.037870257176322725,0.003227486121839514,0.0,0.0,0.0,33.73597848394261,96.0000000000007,,65.17380206825796,,37.56710138152275,66.66666666666669,,,,13.338874999988173,4.68749999999581,,6.904614825575253,,11.978565911420889,6.749999999994013,,,