|
925 | 925 | "def summary_bars_plotter(summary_bars: list, results: object, ax_to_plot: object,\n", |
926 | 926 | " float_contrast: bool,summary_bars_kwargs: dict, ci_type: str,\n", |
927 | 927 | " ticks_to_plot: list, color_col: str, plot_palette_raw: dict, \n", |
928 | | - " proportional: bool, is_paired: bool, horizontal: bool):\n", |
| 928 | + " proportional: bool, show_pairs: bool, horizontal: bool):\n", |
929 | 929 | " \"\"\"\n", |
930 | 930 | " Add summary bars to the contrast plot. Currently only functional for Vertical plots.\n", |
931 | 931 | "\n", |
|
951 | 951 | " Dictionary of colors used in the plot.\n", |
952 | 952 | " proportional : bool\n", |
953 | 953 | " Whether the data is proportional.\n", |
954 | | - " is_paired : bool\n", |
955 | | - " Whether the data is paired.\n", |
| 954 | + " show_pairs : bool\n", |
| 955 | + " Whether the data is paired and shown in pairs.\n", |
956 | 956 | " horizontal : bool\n", |
957 | 957 | " Whether the plot is horizontal.\n", |
958 | 958 | " \"\"\"\n", |
|
974 | 974 | " [summary_bars_kwargs.get('color')]*int(max(ticks_to_plot)+1)\n", |
975 | 975 | " if summary_bars_kwargs.get('color') is not None\n", |
976 | 976 | " else ['black']*int(max(ticks_to_plot)+1)\n", |
977 | | - " if color_col is not None or (proportional and is_paired) or is_paired \n", |
| 977 | + " if color_col is not None or (proportional and show_pairs) or show_pairs \n", |
978 | 978 | " else list(plot_palette_raw.values())\n", |
979 | 979 | " )\n", |
980 | 980 | " summary_bars_kwargs.pop('color')\n", |
|
1013 | 1013 | "def contrast_bars_plotter(results: object, ax_to_plot: object, swarm_plot_ax: object,\n", |
1014 | 1014 | " ticks_to_plot: list, contrast_bars_kwargs: dict, color_col: str, \n", |
1015 | 1015 | " plot_palette_raw: dict, show_mini_meta: bool, mini_meta_delta: object, \n", |
1016 | | - " show_delta2: bool, delta_delta: object, is_paired: bool,\n", |
| 1016 | + " show_delta2: bool, delta_delta: object, show_pairs: bool,\n", |
1017 | 1017 | " horizontal: bool, idx: list):\n", |
1018 | 1018 | " \"\"\"\n", |
1019 | 1019 | " Add contrast bars to the contrast plot.\n", |
|
1042 | 1042 | " Whether to show the delta-delta.\n", |
1043 | 1043 | " delta_delta : object\n", |
1044 | 1044 | " delta-delta object.\n", |
1045 | | - " is_paired : bool\n", |
1046 | | - " Whether the data is paired.\n", |
| 1045 | + " show_pairs : bool\n", |
| 1046 | + " Whether the data is paired and shown in pairs.\n", |
1047 | 1047 | " horizontal : bool\n", |
1048 | 1048 | " Whether the plot is horizontal.\n", |
1049 | 1049 | " idx : list\n", |
|
1062 | 1062 | " [contrast_bars_kwargs.get('color')] * int(max(ticks_to_plot) + 1) \n", |
1063 | 1063 | " if contrast_bars_kwargs.get('color') is not None \n", |
1064 | 1064 | " else ['black'] * int(max(ticks_to_plot) + 1) \n", |
1065 | | - " if color_col is not None or is_paired \n", |
| 1065 | + " if color_col is not None or show_pairs\n", |
1066 | 1066 | " else plot_palette_raw\n", |
1067 | 1067 | " )\n", |
1068 | 1068 | " contrast_bars_kwargs.pop('color')\n", |
1069 | 1069 | "\n", |
1070 | 1070 | " # alpha\n", |
1071 | | - " contrast_bars_kwargs['alpha'] = contrast_bars_kwargs.get('alpha', 0.15 if color_col is not None or is_paired else 0.25)\n", |
| 1071 | + " contrast_bars_kwargs['alpha'] = contrast_bars_kwargs.get('alpha', 0.15 if color_col is not None or show_pairs else 0.25)\n", |
1072 | 1072 | "\n", |
1073 | 1073 | " for contrast_bars_x,contrast_bars_y in zip(ticks_to_plot, contrast_means):\n", |
1074 | 1074 | " idx_selector = (\n", |
|
1093 | 1093 | "\n", |
1094 | 1094 | "def swarm_bars_plotter(plot_data: object, xvar: str, yvar: str, ax: object,\n", |
1095 | 1095 | " swarm_bars_kwargs: dict, color_col: str, plot_palette_raw: dict, \n", |
1096 | | - " is_paired: bool, idx: list):\n", |
| 1096 | + " show_pairs: bool, idx: list):\n", |
1097 | 1097 | " \"\"\"\n", |
1098 | 1098 | " Add bars to the raw data plot. Currently only for vertical plots.\n", |
1099 | 1099 | "\n", |
|
1113 | 1113 | " Column name of the color column.\n", |
1114 | 1114 | " plot_palette_raw : dict\n", |
1115 | 1115 | " Dictionary of colors used in the plot.\n", |
1116 | | - " is_paired : bool\n", |
1117 | | - " Whether the data is paired.\n", |
| 1116 | + " show_pairs : bool\n", |
| 1117 | + " Whether the data is paired and shown in pairs.\n", |
1118 | 1118 | " idx : list\n", |
1119 | 1119 | " List of indices of the raw groups.\n", |
1120 | 1120 | " \"\"\"\n", |
|
1134 | 1134 | " [swarm_bars_kwargs.get('color')] * (len(swarm_bars_order) + 1) \n", |
1135 | 1135 | " if swarm_bars_kwargs.get('color') is not None \n", |
1136 | 1136 | " else ['black']*(len(swarm_bars_order)+1)\n", |
1137 | | - " if color_col is not None or is_paired\n", |
| 1137 | + " if color_col is not None or show_pairs\n", |
1138 | 1138 | " else plot_palette_raw\n", |
1139 | 1139 | " )\n", |
1140 | 1140 | " swarm_bars_kwargs.pop('color')\n", |
1141 | 1141 | "\n", |
1142 | 1142 | " # alpha\n", |
1143 | | - " swarm_bars_kwargs['alpha'] = swarm_bars_kwargs.get('alpha', 0.15 if color_col is not None or is_paired else 0.25)\n", |
| 1143 | + " swarm_bars_kwargs['alpha'] = swarm_bars_kwargs.get('alpha', 0.15 if color_col is not None or show_pairs else 0.25)\n", |
1144 | 1144 | "\n", |
1145 | 1145 | " for swarm_bars_x,swarm_bars_y in zip(np.arange(0,len(swarm_bars_order)+1,1), swarm_means):\n", |
1146 | 1146 | " idx_selector = (\n", |
|
0 commit comments