Range measurements vary by frequency channel

I have written software running on top of the DW1000 Device Driver API that varies the frequency channel and preamble on sequential TWR measurements. When used between two devices kept the same distance apart I see the result of the range calculation varies by frequency channel with the ranges varying from 290cm to 350cm. The range typically decreases as the channel number increases. This has surprised me since the TWR distance algorithm is just based on times. It doesn’t include frequency channel.
I have discovered the dwt_getrangebias() function in the API which calculates a range correction value depending on channel, range and PRF. According to the documentation the function was removed from the API in release 2.1 but it is still present in deca_range_tables.c. Using the function does bring the range values a little closer together but not enough.
Please can anyone suggest what I may be doing wrong to have range varying by frequency channel. Also, why was dwt_getrangebias() deemed to be necessary in the past but no longer?