diff options
author | Muriithi Frederick Muriuki | 2021-07-21 08:44:09 +0300 |
---|---|---|
committer | Muriithi Frederick Muriuki | 2021-07-21 08:44:09 +0300 |
commit | a5d4868c6d2f38d3e6fd0409e08413c3569ce356 (patch) | |
tree | 7208485a407dcc515161a498292284da388dfe66 /gn3/computations | |
parent | 8dc60fd93b9eab9fd655a1f0c23ed038d4ac3eed (diff) | |
download | genenetwork3-a5d4868c6d2f38d3e6fd0409e08413c3569ce356.tar.gz |
Extract tests from code in GN1
Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/slink.py: Add dummy `nearest' function
* tests/unit/computations/test_slink.py: Add some tests
This commit adds tests to try and reproduce the working of the `nearest'
function in:
https://github.com/genenetwork/genenetwork1/blob/master/web/webqtl/heatmap/slink.py
This commit might not yet have extracted all the expected behaviour of the
`nearest' function, and therefore, there is a possibility of a later commit
augmenting the work in this commit.
Diffstat (limited to 'gn3/computations')
-rw-r--r-- | gn3/computations/slink.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/gn3/computations/slink.py b/gn3/computations/slink.py new file mode 100644 index 0000000..bec8597 --- /dev/null +++ b/gn3/computations/slink.py @@ -0,0 +1,8 @@ +class LengthError(BaseException): + pass + +class MirrorError(BaseException): + pass + +def nearest(lists, i, j): + return None |