statgen / locuszoom-api

Flask server code for LocusZoom APIs
https://portaldev.sph.umich.edu/docs/api/v1/
1 stars 3 forks source link

Update Recombination Endpoint #1

Closed MrFlick closed 7 years ago

MrFlick commented 7 years ago

This request updates the recombination rate endpoint to always return values on the ends of the requested region. It will linearly interpolate between observed points when exact positions are not available. This should fix the problem in LocusZoom when a region was too small to return any recombination rate data.

To do this, a lot of functions were refactored into smaller functions so that certain elements could be reused.

The reshaping function has also been updated to return empty arrays when no results are found rather than an empty "data" element.