Releases: m3g/ComplexMixtures.jl
Releases · m3g/ComplexMixtures.jl
v2.10.0
ComplexMixtures v2.10.0
New feature
The indexing and iteration of a ResidueContributions
object was improved, such that:
- When a
ResidueContributions
contain the contributions of more than one residue, the iteration occurs within residues. - When a
ResidueContributions
contain the contribution of a single residue, iteration occurs over the contributions of this residue.
This implies many facilities and greater consistency in iterations over these objects as, for instance, it is possible to extract (for example) the contribution at a given distance for all residues as:
julia> rc = ResidueContributions(R, select(ats, "protein"))
Residue Contributions - 274 residues.
3.51 █ █ █ █ █
3.27 █ █ █
3.03 █ █ █ █ █ █ █ █
2.79 █ ██ █ █ █ █ █ ██ █ █ █
d 2.55 █ █ ██ █ █ █ █ ██ ██ █ █ █ █ █ █ █
2.31 █ █ ██ █ ███ █ ██ ██ ██ █ ██ █ ██ █ █ █
2.07 █ █ █ █ █████ █ ██ ██ ██ █ ██ █ █ ██ █ █
1.83 █ █ █ █ █████ █ ██ █ ██ █ ██ █ ██ █ █
1.59
A1 T33 T66 S98 S130 T162 A194 H226 G258
julia> id = findfirst(>=(2.0), rc.d) # index of distance for 2.0 Angstroms
26
julia> c_at_2 = [ r[id] for r in rc ] # collect contributions for all residues at index id
274-element Vector{Float64}:
0.025795222201597752
0.027637738073140444
⋮
0.0
0.03316528568776853
The above is possible because, for example, rc[1]
returns a "single-residue" ResidueContributions
object, and indexing this object returns the contributions of such residue at each distance.
Similarly, these features allow other Julia functions to be broadcasted over the residue contributions:
getindex.(rc, 26) # returns the contribution at index 26 for all residues (equivalent to the `[ r[id] for r in rc ]` above)
last.(rc) # returns the contribution of each residue at the largest distance
maximum.(rc) # returns the maximum contribution of each residue
findmax.(rc) # returns the maximum and index of the distance maximum of the contributions of each residue
Merged pull requests:
v2.9.0
- Update docs to make
Trajectory
a minor menu.
v2.9.0
ComplexMixtures v2.9.0
New features
- The calls to
mddf
andcoordination_number
now accept the name of the trajetory file and the solute and solvent selections, passing by the construction of theTrajectory
object. This is now the preferred and documented interface:where themddf(trajectory_file, solute, solvent, options) mddf(trajectory_file, solute_and_solvent, options) # for auto-correlations coordination_number(trajectory_file, solute, solvent, option) coordination_number(trajectory_file, solute_and_solvent, options) # for auto-correlations
solute
,solvent
andsolute_and_solvent
objects areAtomSelection
structures.
Other changes:
- documentation updates.
Merged pull requests:
v2.8.5
ComplexMixtures v2.8.5
- Throw ArgumentError messages if
n_random_samples <= 0
or ifsum(frame_weights[considered_range]) <= 0
.
Merged pull requests:
v2.8.4
ComplexMixtures v2.8.4
- Improve error message for ResidueContributions with wrong arguments.
v2.8.3
ComplexMixtures v2.8.3
- Add compatibility to PDBTools.jl v2
Merged pull requests:
v2.8.2
ComplexMixtures v2.8.2
- Fix bug in the computation of contributions of subgroups of solute groups that are discontinous molecules in the structure file.
- Computing contributions is much faster.
- Remove the experimental
_unsafe_types_from_indices
option fromcontributions
, which is not necessary anymore.
Merged pull requests:
v2.8.1
ComplexMixtures v2.8.1
- Add (experimental) option
_unsafe_types_from_indices::Bool
tocontributions
andResidueContributions
, to compute (much) faster the residue contributions. By default, it is set to false, and the previous safe search of types is used.
v2.8.0
ComplexMixtures v2.8.0
New feature:
save
andload
ResidueContributions
objects.- some improved error messages.