voice gender split correlation plots

This commit is contained in:
2026-02-04 13:44:51 +01:00
parent ab78276a97
commit fc76bb0ab5
3 changed files with 360 additions and 81 deletions

View File

@@ -573,41 +573,24 @@ joined_scale_female = joined_scale.filter(pl.col("Voice").is_in(FEMALE_VOICES))
joined_ranking_male = joined_ranking.filter(pl.col("Voice").is_in(MALE_VOICES))
joined_ranking_female = joined_ranking.filter(pl.col("Voice").is_in(FEMALE_VOICES))
# Colors vs Scale 1-10 (Male voices only)
color_corr_scale_male, _ = utils.transform_speaking_style_color_correlation(joined_scale_male, SPEAKING_STYLES)
S.plot_speaking_style_color_correlation(
data=color_corr_scale_male,
title="Correlation: Speaking Style Colors and Voice Scale 1-10 (Male Voices Only)"
# Colors vs Scale 1-10 (grouped by voice gender)
S.plot_speaking_style_color_correlation_by_gender(
data_male=joined_scale_male,
data_female=joined_scale_female,
speaking_styles=SPEAKING_STYLES,
target_column="Voice_Scale_Score",
title="Correlation: Speaking Style Colors and Voice Scale 1-10 (by Voice Gender)",
filename="correlation_speaking_style_and_voice_scale_1-10_by_voice_gender_color",
)
# Colors vs Scale 1-10 (Female voices only)
color_corr_scale_female, _ = utils.transform_speaking_style_color_correlation(joined_scale_female, SPEAKING_STYLES)
S.plot_speaking_style_color_correlation(
data=color_corr_scale_female,
title="Correlation: Speaking Style Colors and Voice Scale 1-10 (Female Voices Only)"
)
# %%
# Colors vs Ranking Points (Male voices only)
color_corr_ranking_male, _ = utils.transform_speaking_style_color_correlation(
joined_ranking_male,
SPEAKING_STYLES,
target_column="Ranking_Points"
)
S.plot_speaking_style_color_correlation(
data=color_corr_ranking_male,
title="Correlation: Speaking Style Colors and Voice Ranking Points (Male Voices Only)"
)
# Colors vs Ranking Points (Female voices only)
color_corr_ranking_female, _ = utils.transform_speaking_style_color_correlation(
joined_ranking_female,
SPEAKING_STYLES,
target_column="Ranking_Points"
)
S.plot_speaking_style_color_correlation(
data=color_corr_ranking_female,
title="Correlation: Speaking Style Colors and Voice Ranking Points (Female Voices Only)"
# Colors vs Ranking Points (grouped by voice gender)
S.plot_speaking_style_color_correlation_by_gender(
data_male=joined_ranking_male,
data_female=joined_ranking_female,
speaking_styles=SPEAKING_STYLES,
target_column="Ranking_Points",
title="Correlation: Speaking Style Colors and Voice Ranking Points (by Voice Gender)",
filename="correlation_speaking_style_and_voice_ranking_points_by_voice_gender_color",
)
# %%
@@ -659,15 +642,17 @@ for _style, _traits in SPEAKING_STYLES.items():
mo.md(_content)
# %%
# Individual Traits vs Scale 1-10 (Male voices only)
_content = """### Individual Traits vs Scale 1-10 (Male Voices Only)\n\n"""
# Individual Traits vs Scale 1-10 (grouped by voice gender)
_content = """### Individual Traits vs Scale 1-10 (by Voice Gender)\n\n"""
for _style, _traits in SPEAKING_STYLES.items():
_fig = S.plot_speaking_style_scale_correlation(
data=joined_scale_male,
_fig = S.plot_speaking_style_scale_correlation_by_gender(
data_male=joined_scale_male,
data_female=joined_scale_female,
style_color=_style,
style_traits=_traits,
title=f"Correlation: Speaking Style {_style} and Voice Scale 1-10 (Male Voices Only)",
title=f"Correlation: Speaking Style {_style} and Voice Scale 1-10 (by Voice Gender)",
filename=f"correlation_speaking_style_and_voice_scale_1-10_by_voice_gender_{_style.lower()}",
)
_content += f"""
#### Speaking Style **{_style}**:
@@ -678,53 +663,17 @@ for _style, _traits in SPEAKING_STYLES.items():
mo.md(_content)
# %%
# Individual Traits vs Scale 1-10 (Female voices only)
_content = """### Individual Traits vs Scale 1-10 (Female Voices Only)\n\n"""
# Individual Traits vs Ranking Points (grouped by voice gender)
_content = """### Individual Traits vs Ranking Points (by Voice Gender)\n\n"""
for _style, _traits in SPEAKING_STYLES.items():
_fig = S.plot_speaking_style_scale_correlation(
data=joined_scale_female,
_fig = S.plot_speaking_style_ranking_correlation_by_gender(
data_male=joined_ranking_male,
data_female=joined_ranking_female,
style_color=_style,
style_traits=_traits,
title=f"Correlation: Speaking Style {_style} and Voice Scale 1-10 (Female Voices Only)",
)
_content += f"""
#### Speaking Style **{_style}**:
{mo.ui.altair_chart(_fig)}
"""
mo.md(_content)
# %%
# Individual Traits vs Ranking Points (Male voices only)
_content = """### Individual Traits vs Ranking Points (Male Voices Only)\n\n"""
for _style, _traits in SPEAKING_STYLES.items():
_fig = S.plot_speaking_style_ranking_correlation(
data=joined_ranking_male,
style_color=_style,
style_traits=_traits,
title=f"Correlation: Speaking Style {_style} and Voice Ranking Points (Male Voices Only)",
)
_content += f"""
#### Speaking Style **{_style}**:
{mo.ui.altair_chart(_fig)}
"""
mo.md(_content)
# %%
# Individual Traits vs Ranking Points (Female voices only)
_content = """### Individual Traits vs Ranking Points (Female Voices Only)\n\n"""
for _style, _traits in SPEAKING_STYLES.items():
_fig = S.plot_speaking_style_ranking_correlation(
data=joined_ranking_female,
style_color=_style,
style_traits=_traits,
title=f"Correlation: Speaking Style {_style} and Voice Ranking Points (Female Voices Only)",
title=f"Correlation: Speaking Style {_style} and Voice Ranking Points (by Voice Gender)",
filename=f"correlation_speaking_style_and_voice_ranking_points_by_voice_gender_{_style.lower()}",
)
_content += f"""
#### Speaking Style **{_style}**: