biotite 1.0.1__cp312-cp312-win_amd64.whl → 1.2.0__cp312-cp312-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of biotite might be problematic. Click here for more details.

Files changed (177) hide show
  1. biotite/application/application.py +3 -3
  2. biotite/application/autodock/app.py +1 -1
  3. biotite/application/blast/webapp.py +1 -1
  4. biotite/application/clustalo/app.py +1 -1
  5. biotite/application/dssp/app.py +13 -3
  6. biotite/application/localapp.py +36 -2
  7. biotite/application/msaapp.py +10 -10
  8. biotite/application/muscle/app3.py +5 -18
  9. biotite/application/muscle/app5.py +5 -5
  10. biotite/application/sra/app.py +0 -5
  11. biotite/application/util.py +22 -2
  12. biotite/application/viennarna/rnaalifold.py +8 -8
  13. biotite/application/viennarna/rnaplot.py +9 -3
  14. biotite/application/viennarna/util.py +1 -1
  15. biotite/application/webapp.py +1 -1
  16. biotite/database/afdb/__init__.py +12 -0
  17. biotite/database/afdb/download.py +191 -0
  18. biotite/database/entrez/dbnames.py +10 -0
  19. biotite/database/entrez/download.py +9 -10
  20. biotite/database/entrez/key.py +1 -1
  21. biotite/database/entrez/query.py +5 -4
  22. biotite/database/pubchem/download.py +6 -6
  23. biotite/database/pubchem/error.py +10 -0
  24. biotite/database/pubchem/query.py +12 -23
  25. biotite/database/rcsb/download.py +3 -2
  26. biotite/database/rcsb/query.py +8 -9
  27. biotite/database/uniprot/check.py +22 -17
  28. biotite/database/uniprot/download.py +3 -6
  29. biotite/database/uniprot/query.py +4 -5
  30. biotite/file.py +14 -2
  31. biotite/interface/__init__.py +19 -0
  32. biotite/interface/openmm/__init__.py +16 -0
  33. biotite/interface/openmm/state.py +93 -0
  34. biotite/interface/openmm/system.py +227 -0
  35. biotite/interface/pymol/__init__.py +198 -0
  36. biotite/interface/pymol/cgo.py +346 -0
  37. biotite/interface/pymol/convert.py +185 -0
  38. biotite/interface/pymol/display.py +267 -0
  39. biotite/interface/pymol/object.py +1226 -0
  40. biotite/interface/pymol/shapes.py +178 -0
  41. biotite/interface/pymol/startup.py +169 -0
  42. biotite/interface/rdkit/__init__.py +15 -0
  43. biotite/interface/rdkit/mol.py +490 -0
  44. biotite/interface/version.py +71 -0
  45. biotite/interface/warning.py +19 -0
  46. biotite/sequence/align/__init__.py +0 -4
  47. biotite/sequence/align/alignment.py +49 -14
  48. biotite/sequence/align/banded.cp312-win_amd64.pyd +0 -0
  49. biotite/sequence/align/banded.pyx +26 -26
  50. biotite/sequence/align/cigar.py +2 -2
  51. biotite/sequence/align/kmeralphabet.cp312-win_amd64.pyd +0 -0
  52. biotite/sequence/align/kmeralphabet.pyx +19 -2
  53. biotite/sequence/align/kmersimilarity.cp312-win_amd64.pyd +0 -0
  54. biotite/sequence/align/kmertable.cp312-win_amd64.pyd +0 -0
  55. biotite/sequence/align/kmertable.pyx +58 -48
  56. biotite/sequence/align/localgapped.cp312-win_amd64.pyd +0 -0
  57. biotite/sequence/align/localgapped.pyx +47 -47
  58. biotite/sequence/align/localungapped.cp312-win_amd64.pyd +0 -0
  59. biotite/sequence/align/localungapped.pyx +10 -10
  60. biotite/sequence/align/matrix.py +284 -57
  61. biotite/sequence/align/matrix_data/3Di.mat +24 -0
  62. biotite/sequence/align/matrix_data/PB.license +21 -0
  63. biotite/sequence/align/matrix_data/PB.mat +18 -0
  64. biotite/sequence/align/multiple.cp312-win_amd64.pyd +0 -0
  65. biotite/sequence/align/pairwise.cp312-win_amd64.pyd +0 -0
  66. biotite/sequence/align/pairwise.pyx +35 -35
  67. biotite/sequence/align/permutation.cp312-win_amd64.pyd +0 -0
  68. biotite/sequence/align/selector.cp312-win_amd64.pyd +0 -0
  69. biotite/sequence/align/selector.pyx +2 -2
  70. biotite/sequence/align/statistics.py +1 -1
  71. biotite/sequence/align/tracetable.cp312-win_amd64.pyd +0 -0
  72. biotite/sequence/alphabet.py +5 -2
  73. biotite/sequence/annotation.py +19 -13
  74. biotite/sequence/codec.cp312-win_amd64.pyd +0 -0
  75. biotite/sequence/codon.py +1 -2
  76. biotite/sequence/graphics/alignment.py +25 -39
  77. biotite/sequence/graphics/color_schemes/3di_flower.json +48 -0
  78. biotite/sequence/graphics/color_schemes/pb_flower.json +2 -1
  79. biotite/sequence/graphics/colorschemes.py +44 -11
  80. biotite/sequence/graphics/dendrogram.py +4 -2
  81. biotite/sequence/graphics/features.py +2 -2
  82. biotite/sequence/graphics/logo.py +10 -12
  83. biotite/sequence/io/fasta/convert.py +1 -2
  84. biotite/sequence/io/fasta/file.py +1 -1
  85. biotite/sequence/io/fastq/file.py +3 -3
  86. biotite/sequence/io/genbank/file.py +3 -3
  87. biotite/sequence/io/genbank/sequence.py +2 -0
  88. biotite/sequence/io/gff/convert.py +1 -1
  89. biotite/sequence/io/gff/file.py +1 -2
  90. biotite/sequence/phylo/nj.cp312-win_amd64.pyd +0 -0
  91. biotite/sequence/phylo/tree.cp312-win_amd64.pyd +0 -0
  92. biotite/sequence/phylo/upgma.cp312-win_amd64.pyd +0 -0
  93. biotite/sequence/profile.py +105 -29
  94. biotite/sequence/search.py +0 -1
  95. biotite/sequence/seqtypes.py +136 -8
  96. biotite/sequence/sequence.py +1 -2
  97. biotite/setup_ccd.py +197 -0
  98. biotite/structure/__init__.py +6 -3
  99. biotite/structure/alphabet/__init__.py +25 -0
  100. biotite/structure/alphabet/encoder.py +332 -0
  101. biotite/structure/alphabet/encoder_weights_3di.kerasify +0 -0
  102. biotite/structure/alphabet/i3d.py +109 -0
  103. biotite/structure/alphabet/layers.py +86 -0
  104. biotite/structure/alphabet/pb.license +21 -0
  105. biotite/structure/alphabet/pb.py +170 -0
  106. biotite/structure/alphabet/unkerasify.py +128 -0
  107. biotite/structure/atoms.py +163 -66
  108. biotite/structure/basepairs.py +26 -26
  109. biotite/structure/bonds.cp312-win_amd64.pyd +0 -0
  110. biotite/structure/bonds.pyx +79 -25
  111. biotite/structure/box.py +19 -21
  112. biotite/structure/celllist.cp312-win_amd64.pyd +0 -0
  113. biotite/structure/celllist.pyx +83 -67
  114. biotite/structure/chains.py +5 -37
  115. biotite/structure/charges.cp312-win_amd64.pyd +0 -0
  116. biotite/structure/compare.py +420 -13
  117. biotite/structure/density.py +1 -1
  118. biotite/structure/dotbracket.py +27 -28
  119. biotite/structure/filter.py +8 -8
  120. biotite/structure/geometry.py +74 -127
  121. biotite/structure/hbond.py +17 -19
  122. biotite/structure/info/__init__.py +1 -0
  123. biotite/structure/info/atoms.py +24 -15
  124. biotite/structure/info/bonds.py +12 -6
  125. biotite/structure/info/ccd.py +125 -34
  126. biotite/structure/info/{ccd/components.bcif → components.bcif} +0 -0
  127. biotite/structure/info/groups.py +62 -19
  128. biotite/structure/info/masses.py +9 -6
  129. biotite/structure/info/misc.py +15 -22
  130. biotite/structure/info/radii.py +92 -22
  131. biotite/structure/info/standardize.py +4 -4
  132. biotite/structure/integrity.py +4 -6
  133. biotite/structure/io/general.py +2 -2
  134. biotite/structure/io/gro/file.py +8 -9
  135. biotite/structure/io/mol/convert.py +1 -1
  136. biotite/structure/io/mol/ctab.py +33 -28
  137. biotite/structure/io/mol/mol.py +1 -1
  138. biotite/structure/io/mol/sdf.py +80 -53
  139. biotite/structure/io/pdb/convert.py +4 -3
  140. biotite/structure/io/pdb/file.py +85 -25
  141. biotite/structure/io/pdb/hybrid36.cp312-win_amd64.pyd +0 -0
  142. biotite/structure/io/pdbqt/file.py +36 -36
  143. biotite/structure/io/pdbx/__init__.py +1 -0
  144. biotite/structure/io/pdbx/bcif.py +54 -15
  145. biotite/structure/io/pdbx/cif.py +92 -66
  146. biotite/structure/io/pdbx/component.py +15 -4
  147. biotite/structure/io/pdbx/compress.py +321 -0
  148. biotite/structure/io/pdbx/convert.py +410 -75
  149. biotite/structure/io/pdbx/encoding.cp312-win_amd64.pyd +0 -0
  150. biotite/structure/io/pdbx/encoding.pyx +98 -17
  151. biotite/structure/io/trajfile.py +9 -6
  152. biotite/structure/io/util.py +38 -0
  153. biotite/structure/mechanics.py +0 -1
  154. biotite/structure/molecules.py +141 -156
  155. biotite/structure/pseudoknots.py +7 -13
  156. biotite/structure/repair.py +2 -4
  157. biotite/structure/residues.py +13 -24
  158. biotite/structure/rings.py +335 -0
  159. biotite/structure/sasa.cp312-win_amd64.pyd +0 -0
  160. biotite/structure/sasa.pyx +2 -1
  161. biotite/structure/segments.py +69 -11
  162. biotite/structure/sequence.py +0 -1
  163. biotite/structure/sse.py +0 -2
  164. biotite/structure/superimpose.py +74 -62
  165. biotite/structure/tm.py +581 -0
  166. biotite/structure/transform.py +12 -25
  167. biotite/structure/util.py +76 -4
  168. biotite/version.py +9 -4
  169. biotite/visualize.py +111 -1
  170. {biotite-1.0.1.dist-info → biotite-1.2.0.dist-info}/METADATA +6 -2
  171. {biotite-1.0.1.dist-info → biotite-1.2.0.dist-info}/RECORD +173 -143
  172. biotite/structure/info/ccd/README.rst +0 -8
  173. biotite/structure/info/ccd/amino_acids.txt +0 -1663
  174. biotite/structure/info/ccd/carbohydrates.txt +0 -1135
  175. biotite/structure/info/ccd/nucleotides.txt +0 -798
  176. {biotite-1.0.1.dist-info → biotite-1.2.0.dist-info}/WHEEL +0 -0
  177. {biotite-1.0.1.dist-info → biotite-1.2.0.dist-info}/licenses/LICENSE.rst +0 -0
@@ -39,11 +39,6 @@ def get_molecule_indices(array):
39
39
  Consequently, the length of this list is equal to the number of
40
40
  molecules in the input `array`.
41
41
 
42
- See also
43
- --------
44
- get_molecule_masks
45
- molecule_iter
46
-
47
42
  Examples
48
43
  --------
49
44
  Get an :class:`AtomArray` for ATP and show that it is a single
@@ -63,54 +58,54 @@ def get_molecule_indices(array):
63
58
  >>> print(len(indices))
64
59
  2
65
60
  >>> print(atp[indices[0]])
66
- HET 0 ATP PG P 1.200 -0.230 -6.850
67
- HET 0 ATP O1G O 1.740 1.140 -6.670
68
- HET 0 ATP O2G O 2.120 -1.040 -7.890
69
- HET 0 ATP O3G O -0.300 -0.140 -7.420
70
- HET 0 ATP PB P 0.260 -0.130 -4.450
71
- HET 0 ATP O1B O 0.810 1.230 -4.300
72
- HET 0 ATP O2B O -1.230 -0.040 -5.060
73
- HET 0 ATP O3B O 1.190 -0.990 -5.430
74
- HET 0 ATP PA P -0.740 0.070 -2.070
75
- HET 0 ATP O1A O -2.100 0.140 -2.670
76
- HET 0 ATP O2A O -0.120 1.550 -1.960
77
- HET 0 ATP O3A O 0.200 -0.840 -3.000
78
- HET 0 ATP HOG2 H 2.100 -0.550 -8.730
79
- HET 0 ATP HOG3 H -0.620 -1.050 -7.520
80
- HET 0 ATP HOB2 H -1.550 -0.950 -5.130
81
- HET 0 ATP HOA2 H 0.750 1.460 -1.560
61
+ HET 0 ATP PG P 1.200 -0.226 -6.850
62
+ HET 0 ATP O1G O 1.740 1.140 -6.672
63
+ HET 0 ATP O2G O 2.123 -1.036 -7.891
64
+ HET 0 ATP O3G O -0.302 -0.139 -7.421
65
+ HET 0 ATP PB P 0.255 -0.130 -4.446
66
+ HET 0 ATP O1B O 0.810 1.234 -4.304
67
+ HET 0 ATP O2B O -1.231 -0.044 -5.057
68
+ HET 0 ATP O3B O 1.192 -0.990 -5.433
69
+ HET 0 ATP PA P -0.745 0.068 -2.071
70
+ HET 0 ATP O1A O -2.097 0.143 -2.669
71
+ HET 0 ATP O2A O -0.125 1.549 -1.957
72
+ HET 0 ATP O3A O 0.203 -0.840 -3.002
73
+ HET 0 ATP HOG2 H 2.100 -0.546 -8.725
74
+ HET 0 ATP HOG3 H -0.616 -1.048 -7.522
75
+ HET 0 ATP HOB2 H -1.554 -0.952 -5.132
76
+ HET 0 ATP HOA2 H 0.752 1.455 -1.563
82
77
  >>> print(atp[indices[1]])
83
- HET 0 ATP O5' O -0.840 -0.590 -0.600
84
- HET 0 ATP C5' C -1.690 0.260 0.170
85
- HET 0 ATP C4' C -1.830 -0.310 1.580
86
- HET 0 ATP O4' O -0.540 -0.360 2.230
87
- HET 0 ATP C3' C -2.680 0.630 2.460
88
- HET 0 ATP O3' O -4.030 0.160 2.530
89
- HET 0 ATP C2' C -2.010 0.560 3.860
90
- HET 0 ATP O2' O -2.930 0.040 4.830
91
- HET 0 ATP C1' C -0.830 -0.420 3.650
92
- HET 0 ATP N9 N 0.330 0.020 4.430
93
- HET 0 ATP C8 C 1.300 0.880 4.010
94
- HET 0 ATP N7 N 2.180 1.040 4.960
95
- HET 0 ATP C5 C 1.830 0.300 6.030
96
- HET 0 ATP C6 C 2.390 0.080 7.300
97
- HET 0 ATP N6 N 3.560 0.710 7.680
98
- HET 0 ATP N1 N 1.760 -0.750 8.140
99
- HET 0 ATP C2 C 0.640 -1.350 7.780
100
- HET 0 ATP N3 N 0.090 -1.180 6.600
101
- HET 0 ATP C4 C 0.640 -0.370 5.700
102
- HET 0 ATP H5'1 H -2.680 0.310 -0.300
103
- HET 0 ATP H5'2 H -1.260 1.260 0.220
104
- HET 0 ATP H4' H -2.280 -1.300 1.550
105
- HET 0 ATP H3' H -2.650 1.650 2.080
106
- HET 0 ATP HO3' H -4.520 0.790 3.090
107
- HET 0 ATP H2' H -1.650 1.540 4.160
108
- HET 0 ATP HO2' H -3.670 0.660 4.870
109
- HET 0 ATP H1' H -1.120 -1.430 3.930
110
- HET 0 ATP H8 H 1.330 1.360 3.040
111
- HET 0 ATP HN61 H 3.940 0.550 8.560
112
- HET 0 ATP HN62 H 4.020 1.300 7.060
113
- HET 0 ATP H2 H 0.170 -2.010 8.490
78
+ HET 0 ATP O5' O -0.844 -0.587 -0.604
79
+ HET 0 ATP C5' C -1.694 0.260 0.170
80
+ HET 0 ATP C4' C -1.831 -0.309 1.584
81
+ HET 0 ATP O4' O -0.542 -0.355 2.234
82
+ HET 0 ATP C3' C -2.683 0.630 2.465
83
+ HET 0 ATP O3' O -4.033 0.165 2.534
84
+ HET 0 ATP C2' C -2.011 0.555 3.856
85
+ HET 0 ATP O2' O -2.926 0.043 4.827
86
+ HET 0 ATP C1' C -0.830 -0.418 3.647
87
+ HET 0 ATP N9 N 0.332 0.015 4.425
88
+ HET 0 ATP C8 C 1.302 0.879 4.012
89
+ HET 0 ATP N7 N 2.184 1.042 4.955
90
+ HET 0 ATP C5 C 1.833 0.300 6.033
91
+ HET 0 ATP C6 C 2.391 0.077 7.303
92
+ HET 0 ATP N6 N 3.564 0.706 7.681
93
+ HET 0 ATP N1 N 1.763 -0.747 8.135
94
+ HET 0 ATP C2 C 0.644 -1.352 7.783
95
+ HET 0 ATP N3 N 0.088 -1.178 6.602
96
+ HET 0 ATP C4 C 0.644 -0.371 5.704
97
+ HET 0 ATP H5'1 H -2.678 0.312 -0.296
98
+ HET 0 ATP H5'2 H -1.263 1.259 0.221
99
+ HET 0 ATP H4' H -2.275 -1.304 1.550
100
+ HET 0 ATP H3' H -2.651 1.649 2.078
101
+ HET 0 ATP HO3' H -4.515 0.788 3.094
102
+ HET 0 ATP H2' H -1.646 1.537 4.157
103
+ HET 0 ATP HO2' H -3.667 0.662 4.867
104
+ HET 0 ATP H1' H -1.119 -1.430 3.931
105
+ HET 0 ATP H8 H 1.334 1.357 3.044
106
+ HET 0 ATP HN61 H 3.938 0.548 8.562
107
+ HET 0 ATP HN62 H 4.015 1.303 7.064
108
+ HET 0 ATP H2 H 0.166 -2.014 8.490
114
109
  """
115
110
  if isinstance(array, BondList):
116
111
  bonds = array
@@ -157,11 +152,6 @@ def get_molecule_masks(array):
157
152
  Consequently, the length of this list is equal to the number of
158
153
  molecules in the input `array`.
159
154
 
160
- See also
161
- --------
162
- get_molecule_indices
163
- molecule_iter
164
-
165
155
  Examples
166
156
  --------
167
157
  Get an :class:`AtomArray` for ATP and show that it is a single
@@ -181,54 +171,54 @@ def get_molecule_masks(array):
181
171
  >>> print(len(masks))
182
172
  2
183
173
  >>> print(atp[masks[0]])
184
- HET 0 ATP PG P 1.200 -0.230 -6.850
185
- HET 0 ATP O1G O 1.740 1.140 -6.670
186
- HET 0 ATP O2G O 2.120 -1.040 -7.890
187
- HET 0 ATP O3G O -0.300 -0.140 -7.420
188
- HET 0 ATP PB P 0.260 -0.130 -4.450
189
- HET 0 ATP O1B O 0.810 1.230 -4.300
190
- HET 0 ATP O2B O -1.230 -0.040 -5.060
191
- HET 0 ATP O3B O 1.190 -0.990 -5.430
192
- HET 0 ATP PA P -0.740 0.070 -2.070
193
- HET 0 ATP O1A O -2.100 0.140 -2.670
194
- HET 0 ATP O2A O -0.120 1.550 -1.960
195
- HET 0 ATP O3A O 0.200 -0.840 -3.000
196
- HET 0 ATP HOG2 H 2.100 -0.550 -8.730
197
- HET 0 ATP HOG3 H -0.620 -1.050 -7.520
198
- HET 0 ATP HOB2 H -1.550 -0.950 -5.130
199
- HET 0 ATP HOA2 H 0.750 1.460 -1.560
174
+ HET 0 ATP PG P 1.200 -0.226 -6.850
175
+ HET 0 ATP O1G O 1.740 1.140 -6.672
176
+ HET 0 ATP O2G O 2.123 -1.036 -7.891
177
+ HET 0 ATP O3G O -0.302 -0.139 -7.421
178
+ HET 0 ATP PB P 0.255 -0.130 -4.446
179
+ HET 0 ATP O1B O 0.810 1.234 -4.304
180
+ HET 0 ATP O2B O -1.231 -0.044 -5.057
181
+ HET 0 ATP O3B O 1.192 -0.990 -5.433
182
+ HET 0 ATP PA P -0.745 0.068 -2.071
183
+ HET 0 ATP O1A O -2.097 0.143 -2.669
184
+ HET 0 ATP O2A O -0.125 1.549 -1.957
185
+ HET 0 ATP O3A O 0.203 -0.840 -3.002
186
+ HET 0 ATP HOG2 H 2.100 -0.546 -8.725
187
+ HET 0 ATP HOG3 H -0.616 -1.048 -7.522
188
+ HET 0 ATP HOB2 H -1.554 -0.952 -5.132
189
+ HET 0 ATP HOA2 H 0.752 1.455 -1.563
200
190
  >>> print(atp[masks[1]])
201
- HET 0 ATP O5' O -0.840 -0.590 -0.600
202
- HET 0 ATP C5' C -1.690 0.260 0.170
203
- HET 0 ATP C4' C -1.830 -0.310 1.580
204
- HET 0 ATP O4' O -0.540 -0.360 2.230
205
- HET 0 ATP C3' C -2.680 0.630 2.460
206
- HET 0 ATP O3' O -4.030 0.160 2.530
207
- HET 0 ATP C2' C -2.010 0.560 3.860
208
- HET 0 ATP O2' O -2.930 0.040 4.830
209
- HET 0 ATP C1' C -0.830 -0.420 3.650
210
- HET 0 ATP N9 N 0.330 0.020 4.430
211
- HET 0 ATP C8 C 1.300 0.880 4.010
212
- HET 0 ATP N7 N 2.180 1.040 4.960
213
- HET 0 ATP C5 C 1.830 0.300 6.030
214
- HET 0 ATP C6 C 2.390 0.080 7.300
215
- HET 0 ATP N6 N 3.560 0.710 7.680
216
- HET 0 ATP N1 N 1.760 -0.750 8.140
217
- HET 0 ATP C2 C 0.640 -1.350 7.780
218
- HET 0 ATP N3 N 0.090 -1.180 6.600
219
- HET 0 ATP C4 C 0.640 -0.370 5.700
220
- HET 0 ATP H5'1 H -2.680 0.310 -0.300
221
- HET 0 ATP H5'2 H -1.260 1.260 0.220
222
- HET 0 ATP H4' H -2.280 -1.300 1.550
223
- HET 0 ATP H3' H -2.650 1.650 2.080
224
- HET 0 ATP HO3' H -4.520 0.790 3.090
225
- HET 0 ATP H2' H -1.650 1.540 4.160
226
- HET 0 ATP HO2' H -3.670 0.660 4.870
227
- HET 0 ATP H1' H -1.120 -1.430 3.930
228
- HET 0 ATP H8 H 1.330 1.360 3.040
229
- HET 0 ATP HN61 H 3.940 0.550 8.560
230
- HET 0 ATP HN62 H 4.020 1.300 7.060
231
- HET 0 ATP H2 H 0.170 -2.010 8.490
191
+ HET 0 ATP O5' O -0.844 -0.587 -0.604
192
+ HET 0 ATP C5' C -1.694 0.260 0.170
193
+ HET 0 ATP C4' C -1.831 -0.309 1.584
194
+ HET 0 ATP O4' O -0.542 -0.355 2.234
195
+ HET 0 ATP C3' C -2.683 0.630 2.465
196
+ HET 0 ATP O3' O -4.033 0.165 2.534
197
+ HET 0 ATP C2' C -2.011 0.555 3.856
198
+ HET 0 ATP O2' O -2.926 0.043 4.827
199
+ HET 0 ATP C1' C -0.830 -0.418 3.647
200
+ HET 0 ATP N9 N 0.332 0.015 4.425
201
+ HET 0 ATP C8 C 1.302 0.879 4.012
202
+ HET 0 ATP N7 N 2.184 1.042 4.955
203
+ HET 0 ATP C5 C 1.833 0.300 6.033
204
+ HET 0 ATP C6 C 2.391 0.077 7.303
205
+ HET 0 ATP N6 N 3.564 0.706 7.681
206
+ HET 0 ATP N1 N 1.763 -0.747 8.135
207
+ HET 0 ATP C2 C 0.644 -1.352 7.783
208
+ HET 0 ATP N3 N 0.088 -1.178 6.602
209
+ HET 0 ATP C4 C 0.644 -0.371 5.704
210
+ HET 0 ATP H5'1 H -2.678 0.312 -0.296
211
+ HET 0 ATP H5'2 H -1.263 1.259 0.221
212
+ HET 0 ATP H4' H -2.275 -1.304 1.550
213
+ HET 0 ATP H3' H -2.651 1.649 2.078
214
+ HET 0 ATP HO3' H -4.515 0.788 3.094
215
+ HET 0 ATP H2' H -1.646 1.537 4.157
216
+ HET 0 ATP HO2' H -3.667 0.662 4.867
217
+ HET 0 ATP H1' H -1.119 -1.430 3.931
218
+ HET 0 ATP H8 H 1.334 1.357 3.044
219
+ HET 0 ATP HN61 H 3.938 0.548 8.562
220
+ HET 0 ATP HN62 H 4.015 1.303 7.064
221
+ HET 0 ATP H2 H 0.166 -2.014 8.490
232
222
  """
233
223
  if isinstance(array, BondList):
234
224
  bonds = array
@@ -270,11 +260,6 @@ def molecule_iter(array):
270
260
  molecule : AtomArray or AtomArrayStack
271
261
  A single molecule of the input `array`.
272
262
 
273
- See also
274
- --------
275
- get_molecule_indices
276
- get_molecule_masks
277
-
278
263
  Examples
279
264
  --------
280
265
  Get an :class:`AtomArray` for ATP and break it into two molecules
@@ -288,55 +273,55 @@ def molecule_iter(array):
288
273
  ... print(molecule)
289
274
  ... print()
290
275
  New molecule
291
- HET 0 ATP PG P 1.200 -0.230 -6.850
292
- HET 0 ATP O1G O 1.740 1.140 -6.670
293
- HET 0 ATP O2G O 2.120 -1.040 -7.890
294
- HET 0 ATP O3G O -0.300 -0.140 -7.420
295
- HET 0 ATP PB P 0.260 -0.130 -4.450
296
- HET 0 ATP O1B O 0.810 1.230 -4.300
297
- HET 0 ATP O2B O -1.230 -0.040 -5.060
298
- HET 0 ATP O3B O 1.190 -0.990 -5.430
299
- HET 0 ATP PA P -0.740 0.070 -2.070
300
- HET 0 ATP O1A O -2.100 0.140 -2.670
301
- HET 0 ATP O2A O -0.120 1.550 -1.960
302
- HET 0 ATP O3A O 0.200 -0.840 -3.000
303
- HET 0 ATP HOG2 H 2.100 -0.550 -8.730
304
- HET 0 ATP HOG3 H -0.620 -1.050 -7.520
305
- HET 0 ATP HOB2 H -1.550 -0.950 -5.130
306
- HET 0 ATP HOA2 H 0.750 1.460 -1.560
276
+ HET 0 ATP PG P 1.200 -0.226 -6.850
277
+ HET 0 ATP O1G O 1.740 1.140 -6.672
278
+ HET 0 ATP O2G O 2.123 -1.036 -7.891
279
+ HET 0 ATP O3G O -0.302 -0.139 -7.421
280
+ HET 0 ATP PB P 0.255 -0.130 -4.446
281
+ HET 0 ATP O1B O 0.810 1.234 -4.304
282
+ HET 0 ATP O2B O -1.231 -0.044 -5.057
283
+ HET 0 ATP O3B O 1.192 -0.990 -5.433
284
+ HET 0 ATP PA P -0.745 0.068 -2.071
285
+ HET 0 ATP O1A O -2.097 0.143 -2.669
286
+ HET 0 ATP O2A O -0.125 1.549 -1.957
287
+ HET 0 ATP O3A O 0.203 -0.840 -3.002
288
+ HET 0 ATP HOG2 H 2.100 -0.546 -8.725
289
+ HET 0 ATP HOG3 H -0.616 -1.048 -7.522
290
+ HET 0 ATP HOB2 H -1.554 -0.952 -5.132
291
+ HET 0 ATP HOA2 H 0.752 1.455 -1.563
307
292
  <BLANKLINE>
308
293
  New molecule
309
- HET 0 ATP O5' O -0.840 -0.590 -0.600
310
- HET 0 ATP C5' C -1.690 0.260 0.170
311
- HET 0 ATP C4' C -1.830 -0.310 1.580
312
- HET 0 ATP O4' O -0.540 -0.360 2.230
313
- HET 0 ATP C3' C -2.680 0.630 2.460
314
- HET 0 ATP O3' O -4.030 0.160 2.530
315
- HET 0 ATP C2' C -2.010 0.560 3.860
316
- HET 0 ATP O2' O -2.930 0.040 4.830
317
- HET 0 ATP C1' C -0.830 -0.420 3.650
318
- HET 0 ATP N9 N 0.330 0.020 4.430
319
- HET 0 ATP C8 C 1.300 0.880 4.010
320
- HET 0 ATP N7 N 2.180 1.040 4.960
321
- HET 0 ATP C5 C 1.830 0.300 6.030
322
- HET 0 ATP C6 C 2.390 0.080 7.300
323
- HET 0 ATP N6 N 3.560 0.710 7.680
324
- HET 0 ATP N1 N 1.760 -0.750 8.140
325
- HET 0 ATP C2 C 0.640 -1.350 7.780
326
- HET 0 ATP N3 N 0.090 -1.180 6.600
327
- HET 0 ATP C4 C 0.640 -0.370 5.700
328
- HET 0 ATP H5'1 H -2.680 0.310 -0.300
329
- HET 0 ATP H5'2 H -1.260 1.260 0.220
330
- HET 0 ATP H4' H -2.280 -1.300 1.550
331
- HET 0 ATP H3' H -2.650 1.650 2.080
332
- HET 0 ATP HO3' H -4.520 0.790 3.090
333
- HET 0 ATP H2' H -1.650 1.540 4.160
334
- HET 0 ATP HO2' H -3.670 0.660 4.870
335
- HET 0 ATP H1' H -1.120 -1.430 3.930
336
- HET 0 ATP H8 H 1.330 1.360 3.040
337
- HET 0 ATP HN61 H 3.940 0.550 8.560
338
- HET 0 ATP HN62 H 4.020 1.300 7.060
339
- HET 0 ATP H2 H 0.170 -2.010 8.490
294
+ HET 0 ATP O5' O -0.844 -0.587 -0.604
295
+ HET 0 ATP C5' C -1.694 0.260 0.170
296
+ HET 0 ATP C4' C -1.831 -0.309 1.584
297
+ HET 0 ATP O4' O -0.542 -0.355 2.234
298
+ HET 0 ATP C3' C -2.683 0.630 2.465
299
+ HET 0 ATP O3' O -4.033 0.165 2.534
300
+ HET 0 ATP C2' C -2.011 0.555 3.856
301
+ HET 0 ATP O2' O -2.926 0.043 4.827
302
+ HET 0 ATP C1' C -0.830 -0.418 3.647
303
+ HET 0 ATP N9 N 0.332 0.015 4.425
304
+ HET 0 ATP C8 C 1.302 0.879 4.012
305
+ HET 0 ATP N7 N 2.184 1.042 4.955
306
+ HET 0 ATP C5 C 1.833 0.300 6.033
307
+ HET 0 ATP C6 C 2.391 0.077 7.303
308
+ HET 0 ATP N6 N 3.564 0.706 7.681
309
+ HET 0 ATP N1 N 1.763 -0.747 8.135
310
+ HET 0 ATP C2 C 0.644 -1.352 7.783
311
+ HET 0 ATP N3 N 0.088 -1.178 6.602
312
+ HET 0 ATP C4 C 0.644 -0.371 5.704
313
+ HET 0 ATP H5'1 H -2.678 0.312 -0.296
314
+ HET 0 ATP H5'2 H -1.263 1.259 0.221
315
+ HET 0 ATP H4' H -2.275 -1.304 1.550
316
+ HET 0 ATP H3' H -2.651 1.649 2.078
317
+ HET 0 ATP HO3' H -4.515 0.788 3.094
318
+ HET 0 ATP H2' H -1.646 1.537 4.157
319
+ HET 0 ATP HO2' H -3.667 0.662 4.867
320
+ HET 0 ATP H1' H -1.119 -1.430 3.931
321
+ HET 0 ATP H8 H 1.334 1.357 3.044
322
+ HET 0 ATP HN61 H 3.938 0.548 8.562
323
+ HET 0 ATP HN62 H 4.015 1.303 7.064
324
+ HET 0 ATP H2 H 0.166 -2.014 8.490
340
325
  <BLANKLINE>
341
326
  """
342
327
  if array.bonds is None:
@@ -69,6 +69,11 @@ def pseudoknots(base_pairs, scores=None, max_pseudoknot_order=None):
69
69
  Therefore, there are no pseudoknots between base pairs with the same
70
70
  pseudoknot order.
71
71
 
72
+ References
73
+ ----------
74
+
75
+ .. footbibliography::
76
+
72
77
  Examples
73
78
  --------
74
79
  Remove the pseudoknotted base pair for the sequence *ABCbac*, where
@@ -102,17 +107,6 @@ def pseudoknots(base_pairs, scores=None, max_pseudoknot_order=None):
102
107
  [[0 0 1]]
103
108
  >>> print(dot_bracket(basepairs, 6)[0])
104
109
  (([))]
105
-
106
- See Also
107
- --------
108
- base_pairs
109
- dot_bracket
110
-
111
- References
112
- ----------
113
-
114
- .. footbibliography::
115
-
116
110
  """
117
111
  if len(base_pairs) == 0:
118
112
  # No base pairs -> empty pseudoknot order array
@@ -149,9 +143,9 @@ class _Region:
149
143
 
150
144
  Parameters
151
145
  ----------
152
- base_pairs: ndarray, shape=(n,2), dtype=int
146
+ base_pairs : ndarray, shape=(n,2), dtype=int
153
147
  All base pairs of the structure the region is a subset for.
154
- region_pairs: ndarray, dtype=int
148
+ region_pairs : ndarray, dtype=int
155
149
  The indices of the base pairs in ``base_pairs`` that are part of
156
150
  the region.
157
151
  scores : ndarray, dtype=int, shape=(n,) (default: None)
@@ -48,7 +48,6 @@ def create_continuous_res_ids(atoms, restart_each_chain=True):
48
48
  >>> res_ids, _ = get_residues(atom_array)
49
49
  >>> print(res_ids)
50
50
  [ 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19]
51
-
52
51
  """
53
52
  res_ids_diff = np.zeros(atoms.array_length(), dtype=int)
54
53
  res_starts = get_residue_starts(atoms)
@@ -80,7 +79,7 @@ def infer_elements(atoms):
80
79
 
81
80
  See Also
82
81
  --------
83
- create_atoms_names : The opposite of this function
82
+ create_atoms_names : The opposite of this function.
84
83
 
85
84
  Examples
86
85
  --------
@@ -89,7 +88,6 @@ def infer_elements(atoms):
89
88
  ['N' 'C' 'C' 'O' 'C' 'C' 'O' 'N' 'H' 'H']
90
89
  >>> print(infer_elements(["CA", "C", "C1", "OD1", "HD21", "1H", "FE"]))
91
90
  ['C' 'C' 'C' 'O' 'H' 'H' 'FE']
92
-
93
91
  """
94
92
  if isinstance(atoms, (AtomArray, AtomArrayStack)):
95
93
  atom_names = atoms.atom_name
@@ -117,7 +115,7 @@ def create_atom_names(atoms):
117
115
 
118
116
  See Also
119
117
  --------
120
- infer_elements : The opposite of this function
118
+ infer_elements : The opposite of this function.
121
119
 
122
120
  Notes
123
121
  -----
@@ -69,6 +69,9 @@ def get_residue_starts(array, add_exclusive_stop=False):
69
69
  [ 0 16 35 56 75 92 116 135 157 169 176 183 197 208 219 226 250 264
70
70
  278 292 304]
71
71
  """
72
+ if array.array_length() == 0:
73
+ return np.array([], dtype=int)
74
+
72
75
  # These mask are 'true' at indices where the value changes
73
76
  chain_id_changes = array.chain_id[1:] != array.chain_id[:-1]
74
77
  res_id_changes = array.res_id[1:] != array.res_id[:-1]
@@ -123,9 +126,8 @@ def apply_residue_wise(array, data, function, axis=None):
123
126
  Returns
124
127
  -------
125
128
  processed_data : ndarray
126
- Residue-wise evaluation of `data` by `function`. The size of the
127
- first dimension of this array is equal to the amount of
128
- residues.
129
+ Residue-wise evaluation of `data` by `function`. The size of the first dimension
130
+ of this array is equal to the amount of residues.
129
131
 
130
132
  Examples
131
133
  --------
@@ -193,14 +195,15 @@ def spread_residue_wise(array, input_data):
193
195
  array : AtomArray or AtomArrayStack
194
196
  The atom array (stack) to determine the residues from.
195
197
  input_data : ndarray
196
- The data to be spread. The length of axis=0 must be equal to
197
- the amount of different residue IDs in `array`.
198
+ The data to be spread.
199
+ The length of the 0-th axis must be equal to the amount of different residue IDs
200
+ in `array`.
198
201
 
199
202
  Returns
200
203
  -------
201
204
  output_data : ndarray
202
- Residue-wise spread `input_data`. Length is the same as
203
- `array_length()` of `array`.
205
+ Residue-wise spread `input_data`.
206
+ Length is the same as `array_length()` of `array`.
204
207
 
205
208
  Examples
206
209
  --------
@@ -260,11 +263,6 @@ def get_residue_masks(array, indices):
260
263
  Each array masks the atoms that belong to the same residue as
261
264
  the atom at the given index.
262
265
 
263
- See also
264
- --------
265
- get_residue_starts_for
266
- get_residue_positions
267
-
268
266
  Examples
269
267
  --------
270
268
 
@@ -338,11 +336,6 @@ def get_residue_starts_for(array, indices):
338
336
  The indices that point to the residue starts for the input
339
337
  `indices`.
340
338
 
341
- See also
342
- --------
343
- get_residue_masks
344
- get_residue_positions
345
-
346
339
  Examples
347
340
  --------
348
341
 
@@ -382,14 +375,9 @@ def get_residue_positions(array, indices):
382
375
 
383
376
  Returns
384
377
  -------
385
- start_indices : ndarray, dtype=int, shape=(k,)
378
+ residue_indices : ndarray, dtype=int, shape=(k,)
386
379
  The indices that point to the position of the residues.
387
380
 
388
- See also
389
- --------
390
- get_residue_masks
391
- get_residue_starts_for
392
-
393
381
  Examples
394
382
  --------
395
383
  >>> atom_index = [5, 42]
@@ -569,4 +557,5 @@ def residue_iter(array):
569
557
  """
570
558
  # The exclusive stop is appended to the residue starts
571
559
  starts = get_residue_starts(array, add_exclusive_stop=True)
572
- return segment_iter(array, starts)
560
+ for residue in segment_iter(array, starts):
561
+ yield residue