there might be a duplicate codes in heatmapper.py, method sort_group of class _matrix, starting line 1220 to line 1221
elif sort_using == 'mean':
matrix_avgs = np.nanmean(matrix, axis=1)
elif sort_using == 'mean':
matrix_avgs = np.nanmean(matrix, axis=1)