Return sub group of group that is within distance of both A and B
Am 8/25/22 um 12:37 schrieb rafaelpapp <rafap...@gmail.com>:
--
You received this message because you are subscribed to the Google Groups "MDnalysis discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mdnalysis-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/mdnalysis-discussion/bf2720a1-5547-40b4-828a-01c3f9c8871en%40googlegroups.com.
Am 8/25/22 um 23:23 schrieb rafaelpapp <rafap...@gmail.com>:
To view this discussion on the web visit https://groups.google.com/d/msgid/mdnalysis-discussion/0faa92cc-c10f-4bf1-ac0e-d3977805ed2fn%40googlegroups.com.
On Aug 29, 2022, at 12:28 AM, rafaelpapp <rafap...@gmail.com> wrote:Looking at the code inpackage/MDAnalysis/analysis/distances.pythe between function readsns_group = AtomNeighborSearch(group)
resA = set(ns_group.search(A, distance))
resB = set(ns_group.search(B, distance))
return sum(sorted(resB.intersection(resA)))
I believe that the use of sets, sorted and sum is unnecessary, maybe something like
To view this discussion on the web visit https://groups.google.com/d/msgid/mdnalysis-discussion/c9b6961a-3c9a-49b6-8004-b3879830cbcan%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/mdnalysis-discussion/c145ca74-1e6d-416d-a421-fe97d6e883f2n%40googlegroups.com.