Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

geom_boxplot() doesn't apply alpha to outliers #754

Closed
IKupriyanov-HORIS opened this issue Apr 5, 2023 · 3 comments · Fixed by #814
Closed

geom_boxplot() doesn't apply alpha to outliers #754

IKupriyanov-HORIS opened this issue Apr 5, 2023 · 3 comments · Fixed by #814
Milestone

Comments

@IKupriyanov-HORIS
Copy link
Collaborator

import numpy as np
from lets_plot import *
LetsPlot.setup_html()
n = 100
np.random.seed(42)
x = np.random.choice(['a', 'b', 'c'], size=n)
y = np.random.normal(size=n)
ggplot({'x': x, 'y': y}, aes(x='x', y='y')) + \
    geom_boxplot(alpha=0.2)

image

@alshan
Copy link
Collaborator

alshan commented Apr 5, 2023

My guess, on boxplot (as well as on barchart, area, polygons etc.) alpha is only applied to "fill".

@IKupriyanov-HORIS
Copy link
Collaborator Author

ggplot2 also applies alpha to outliers:
image

@IKupriyanov-HORIS IKupriyanov-HORIS changed the title geom_boxplot() doesn't take into account the alpha geom_boxplot() doesn't apply alpha to outliers Apr 5, 2023
@alshan
Copy link
Collaborator

alshan commented Apr 7, 2023

Outliers appearance is also controlled by additional parameters outlier_[color,fill,shape,size].
In this vein, we could add two more parameters: outlier_alpha, outlier_stroke.

@alshan alshan added this to the New milestone Apr 26, 2023
@alshan alshan modified the milestones: New, 2023Q3 Jun 28, 2023
alshan pushed a commit that referenced this issue Jul 12, 2023
* Fix outlier parameters for geom_boxplot().

* Move default positioning for outliers from Python to Kotlin.

* Add outlier_alpha parameter to the geom_boxplot().

* Mention in future_changes that issue #754 was fixed.

* Undo new behavior for outlier_xxx-params of the geom_boxplot(). Add inner 'fatten' parameter for the outliers.

* Tiny fixes in comments.

* Remove extra import from the geom.py file.

* Fix one comment in GeomProto.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants