Age | Commit message (Expand) | Author |
2021-10-25 | mypy:Incompatible types in assignment fix | Alexander Kabui |
2021-10-25 | mypy fix for none stdout | Alexander Kabui |
2021-10-25 | pylint and pep8 formatting | Alexander Kabui |
2021-10-25 | fix unittests | Alexander Kabui |
2021-10-25 | minor modification for emitting data:add namespaces | Alexander Kabui |
2021-10-25 | pep8 formatting,pylint fixes | Alexander Kabui |
2021-10-25 | add socket obj and emit process | Alexander Kabui |
2021-10-25 | fix issues serializing byte string | Alexander Kabui |
2021-10-25 | rename key to image_data | Alexander Kabui |
2021-10-25 | add function to process images | Alexander Kabui |
2021-10-25 | add function to capture output in real time | Alexander Kabui |
2021-09-27 | add file not found exception | Alexander Kabui |
2021-09-27 | return str error for exception | Alexander Kabui |
2021-09-27 | fix merge conflicts | Alexander Kabui |
2021-09-27 | Narrow the exception and add comments...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Only catch the `FileExistsError` allowing any other exception to pass
through. This tries to conform a little to the review at
https://github.com/genenetwork/genenetwork3/pull/37#discussion_r714552696
| Frederick Muriuki Muriithi |
2021-09-27 | Update terminology: `strain` to `sample`...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Update the terminology used: use `sample` in place of `strain` according to
Zachary's direction at
https://github.com/genenetwork/genenetwork3/pull/37#issuecomment-926043306
| Frederick Muriuki Muriithi |
2021-09-23 | minor fixes for endpoint | Alexander Kabui |
2021-09-23 | Return r error if returncode!=0 | Alexander Kabui |
2021-09-23 | read generated files from r and return output | Alexander Kabui |
2021-09-22 | Fix more pylint errors | Frederick Muriuki Muriithi |
2021-09-22 | Fix typing issues...* Ignore some errors
* Update typing definitions for some portions of code
* Add missing imports
| Frederick Muriuki Muriithi |
2021-09-22 | Fix pylint errors...* Add missing function and module docstrings
* Remove unused imports
* Fix import order
* Rework some code sections to fix issues
* Disable some pylint errors.
| Frederick Muriuki Muriithi |
2021-09-17 | Fix a number of linting issues...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
| Frederick Muriuki Muriithi |
2021-09-16 | run cmd and add exception handler | Alexander Kabui |
2021-09-16 | add function to compose and run wgcna script | Alexander Kabui |
2021-09-16 | function to parse form data and write to json file | Alexander Kabui |
2021-09-15 | init wgcna file to run r script and preprocess data | Alexander Kabui |
2021-09-15 | Reorganise modules...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* The heatmap generation does not fall cleanly within the computations or db
modules. This commit moves it to the higher level gn3 module.
| Frederick Muriuki Muriithi |
2021-09-08 | Ease search for traits and chromosomes...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Return a dict of values rather than list for the traits and chromosomes to
ease searching through the data.
| Muriithi Frederick Muriuki |
2021-09-08 | Parse Chr value as int where possible...* To ease sorting of data by numerical order down the line, sort the "Chr"
values by numerical order.
| Muriithi Frederick Muriuki |
2021-09-08 | Remove extraneous text to ease sorting...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Change the id from 'T<n>' to simply '<n>' to ease sorting of the trait
results by numerical order rather than string order.
| Muriithi Frederick Muriuki |
2021-09-08 | Fix the traits order computations for clustering...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/heatmap.py: Fix ordering function
* tests/unit/computations/test_heatmap.py: update test
The order of the traits is important for the clustering algorithm, since the
clustering seems to use the distance of one trait from another to determine
how to order them.
This commit also gets rid of the xoffset argument that is not important to
the ordering, and was used in the older GN1 to determine how to draw the
clustering lines.
| Muriithi Frederick Muriuki |
2021-09-06 | Provide function to organise parsed QTLReaper results...* gn3/computations/qtlreaper.py: Provide a function to organise the results by
trait for easier use down the line.
* tests/unit/computations/test_qtlreaper.py: provide a test to ensure that the
organising function works as expected.
| Muriithi Frederick Muriuki |
2021-09-06 | Leave "Chr" value as string when parsing...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* The "Chr" value seems to be mostly a name of some sort, despite it being,
seemingly an number. This commit parses the "Chr" value as a string.
It also updates the tests to expec a string, rather than a number for "Chr"
values.
| Muriithi Frederick Muriuki |
2021-09-06 | Handle type-coercion exceptions...* gn3/computations/qtlreaper.py: handle exceptions
Sometimes, the values being parsed are plain strings and cannot be cast to
the float types. This commit handles that by casting only those values that
can be cast to float, and returning the others as strings.
| Muriithi Frederick Muriuki |
2021-09-06 | Find nearest marker...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Migrate the `web.webqtl.heatmap.Heatmap.getNearestMarker` function in GN1 to
GN3.
| Muriithi Frederick Muriuki |
2021-08-31 | Fix linting errors, minor bugs and reorganise code...* Fix some linting errors and some minor bugs caught by the linter.
Move the `random_string` function to separate module for use in multiple
places in the code.
| Muriithi Frederick Muriuki |
2021-08-31 | Update `heatmap_data` function: remove extraneous data...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/heatmap.py: update function
* gn3/db/traits.py: new function
Remove extraneous data and arguments from the function.
- Load the genotype file
- Generate traits file
- Provide both raw traits data, and exported traits data in return
| Muriithi Frederick Muriuki |
2021-08-31 | Parse QTLReaper outputs...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/qtlreaper.py: pass output files
* tests/unit/computations/data/qtlreaper/main_output_sample.txt: sample test
data
* tests/unit/computations/data/qtlreaper/permu_output_sample.txt: sample test
data
* tests/unit/computations/test_qtlreaper.py: add tests
Add code to parse the QTLReaper output data files.
| Muriithi Frederick Muriuki |
2021-08-31 | Fix bugs with `run_reaper` function...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/qtlreaper.py: Fix some bugs
* qtlfilesexport.py: Test out running rust-qtlreaper
Test out the qtlreaper interface code and fix some bugs caught in the
process.
| Muriithi Frederick Muriuki |
2021-08-30 | Fix issues with traits file format...* README.md: update header: Traits ==> Trait
* gn3/computations/qtlreaper.py: update header: Traits ==> Trait
* qtlfilesexport.py: Choose only BXD strains
Rename the first column header from "Traits" to "Trait" to correspond with
what `rust-qtlreaper` expects.
Choose only the BXD strains for the proof-of-concept example - this helped
bring out the fact that the traits file SHOULD NOT contain a strain column
for a strain that does not exist in the genotype file in consideration.
If the traits file has a strain column which does not exist in the genotype
file, then `rust-qtlreaper` fails with a panic, since, from what I can tell,
it tries to get a value from the genotype file for the non-existent strain,
which results to a `None` type. Subsequent attempts at running an operation
on the `None` type lead to the panic.
| Muriithi Frederick Muriuki |
2021-08-30 | Remove empty line...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Remove empty line at the end of the traits file
| Muriithi Frederick Muriuki |
2021-08-30 | Fix some linting errors and minor bugs. | Muriithi Frederick Muriuki |
2021-08-30 | Implement module for interfacing with rust-qtlreaper...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/heatmap.py: move `generate_traits_file` function to new
module
* gn3/computations/qtlreaper.py: new module to interface with the
`rust-qtlreaper` utility.
* gn3/settings.py: Provide setting for the path to the `rust-qtlreaper`
utility
* qtlfilesexport.py: Move `random_string` function to new module. Update to
use functions in new module.
Provide a module with functions to be used to interface with
`rust-qtlreaper`. This module essentially contains all the functions that
are needed to build the files needed for, and to run the qtlreaper utility.
| Muriithi Frederick Muriuki |
2021-08-27 | Provide intermediate data in final results...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Seeing as not every requirement/feature has been migrated over at this time,
this commit just provides all the intermediate data representations in the
final return of the function for later use down the line.
| Muriithi Frederick Muriuki |
2021-08-27 | Export trait data to file...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Provide a function to export the given strains and traits data into a traits
file for use with `rust-qtlreaper`.
| Muriithi Frederick Muriuki |
2021-08-27 | Rework strains and trait values retrieval...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* Rework the strains and values retrieval function to more closely correspond
to the working of the original code in GN1
| Muriithi Frederick Muriuki |
2021-08-20 | Merge branch 'main' of github.com:genenetwork/genenetwork3 into heatmap_gener... | Muriithi Frederick Muriuki |
2021-08-20 | Fix typing issue(s) caught by mypy...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/heatmap.py: Use `Sequence` type not `Iterator` type
| Muriithi Frederick Muriuki |
2021-08-20 | Retrieve the strains with valid values...Issue:
https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi
* gn3/computations/heatmap.py: add function to get strains with values
* tests/unit/computations/test_heatmap.py: new tests
Add function to get the strains whose values are not `None` from the
`trait_data` object passed in.
This migrates
https://github.com/genenetwork/genenetwork1/blob/master/web/webqtl/heatmap/Heatmap.py#L215-221
into a separate function that can handle that and be tested independently of
any other code.
| Muriithi Frederick Muriuki |