|
347 | 347 | " for i in range(len(idx)):\n", |
348 | 348 | " filled.append(False)\n", |
349 | 349 | " filled.extend([True] * (len(idx[i]) - 1))\n", |
350 | | - " print(f\"filled is {filled}\")\n", |
351 | 350 | "\n", |
352 | 351 | " names = color_groups if not color_by_subgroups else idx\n", |
353 | 352 | " n_groups = len(color_groups)\n", |
|
360 | 359 | " unsat_colors = sns.color_palette(n_colors=n_groups)\n", |
361 | 360 | " if empty_circle and not color_by_subgroups:\n", |
362 | 361 | " unsat_colors = [sns.color_palette(\"gray\")[3]] + unsat_colors\n", |
363 | | - " print(unsat_colors)\n", |
364 | 362 | " else:\n", |
365 | 363 | " if isinstance(custom_pal, dict):\n", |
366 | 364 | " groups_in_palette = {\n", |
|
823 | 821 | " if bootstraps_color_by_group:\n", |
824 | 822 | " line_colors.append(plot_palette_raw[all_plot_groups[jj]])\n", |
825 | 823 | "\n", |
826 | | - " # Break the loop since hue in Seaborn adds collections to axes and it will result in index out of range\n", |
827 | | - " if jj >= n_groups - 1 and color_col is None:\n", |
828 | | - " break\n", |
829 | | - "\n", |
830 | 824 | " if len(line_colors) != len(all_plot_groups):\n", |
831 | 825 | " line_colors = ytick_color\n", |
832 | 826 | "\n", |
| 827 | + " # hue in swarmplot would add collections to axes which will result in len(xspans) = len(all_plot_groups) + len(unique groups in hue)\n", |
| 828 | + " if len(xspans) > len(all_plot_groups):\n", |
| 829 | + " xspans = xspans[:len(all_plot_groups)]\n", |
| 830 | + "\n", |
833 | 831 | " error_bar(\n", |
834 | 832 | " plot_data,\n", |
835 | 833 | " x=xvar,\n", |
|
0 commit comments