@@ -282,7 +282,7 @@ def get_heatmap(analysis=None,
282282
283283 string_to_add = ''
284284
285- string_to_add = string_to_add + str (round (pairwise_content ['mean' ],4 ))
285+ string_to_add = string_to_add + str (format ( round (pairwise_content ['mean' ],4 ), '.4f' ))
286286 string_to_add = string_to_add + '\n '
287287 n_info_per_line += 1
288288
@@ -296,16 +296,16 @@ def get_heatmap(analysis=None,
296296
297297 if 'p_x_wins' in pairwise_keys :
298298
299- string_to_add = string_to_add + str (round (pairwise_content ['p-x-wins' ],4 )) + ' / '
300- string_to_add = string_to_add + str (round (pairwise_content ['p-rope' ],4 )) + ' / '
301- string_to_add = string_to_add + str (round (pairwise_content ['p-y-wins' ],4 ))
299+ string_to_add = string_to_add + str (format ( round (pairwise_content ['p-x-wins' ],4 ), '.4f' )) + ' / '
300+ string_to_add = string_to_add + str (format ( round (pairwise_content ['p-rope' ],4 ), '.4f' )) + ' / '
301+ string_to_add = string_to_add + str (format ( round (pairwise_content ['p-y-wins' ],4 ), '.4f' ))
302302 string_to_add = string_to_add + '\n '
303303 n_info_per_line += 1
304304
305305 if 'pvalue' in pairwise_keys :
306306
307307 string_to_add = string_to_add
308- _p_value = round (pairwise_content ['pvalue' ],4 )
308+ _p_value = format ( round (pairwise_content ['pvalue' ],4 ), '.4f' )
309309 if _p_value == 0 :
310310 string_to_add = string_to_add + "< " + str (1e-4 )
311311 else :
@@ -694,7 +694,7 @@ def _get_line_heatmap(proposed_method,
694694
695695 string_to_add = ''
696696
697- string_to_add = string_to_add + str (round (pairwise_content ['mean' ],4 ))
697+ string_to_add = string_to_add + str (format ( round (pairwise_content ['mean' ],4 ), '.4f' ))
698698 string_to_add = string_to_add + '\n '
699699 n_info_per_line += 1
700700
@@ -708,16 +708,16 @@ def _get_line_heatmap(proposed_method,
708708
709709 if 'p_x_wins' in pairwise_keys :
710710
711- string_to_add = string_to_add + str (round (pairwise_content ['p-x-wins' ],4 )) + ' / '
712- string_to_add = string_to_add + str (round (pairwise_content ['p-rope' ],4 )) + ' / '
713- string_to_add = string_to_add + str (round (pairwise_content ['p-y-wins' ],4 ))
711+ string_to_add = string_to_add + str (format ( round (pairwise_content ['p-x-wins' ],4 ), '.4f' )) + ' / '
712+ string_to_add = string_to_add + str (format ( round (pairwise_content ['p-rope' ],4 ), '.4f' )) + ' / '
713+ string_to_add = string_to_add + str (format ( round (pairwise_content ['p-y-wins' ],4 ), '.4f' ))
714714 string_to_add = string_to_add + '\n '
715715 n_info_per_line += 1
716716
717717 if 'pvalue' in pairwise_keys :
718718
719719 string_to_add = string_to_add
720- _p_value = round (pairwise_content ['pvalue' ],4 )
720+ _p_value = format ( round (pairwise_content ['pvalue' ],4 ), '.4f' )
721721 if _p_value == 0 :
722722 string_to_add = string_to_add + "< " + str (1e-4 )
723723 else :
0 commit comments