Skip to content

Commit

Permalink
Name bikeshedding
Browse files Browse the repository at this point in the history
  • Loading branch information
mwaskom committed Oct 5, 2021
1 parent 7e4a62b commit 966218f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions seaborn/_core/mappings.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,11 @@ def _ensure_list_not_too_short(self, levels: list, values: list) -> list:

class DiscreteSemantic(Semantic):

_provided: list | dict | None
_values: list | dict | None

def __init__(self, values: list | dict | None = None, variable: str = "value"):

self._provided = values
self._values = values
self.variable = variable

def _default_values(self, n: int) -> list:
Expand All @@ -95,7 +95,7 @@ def setup(
scale: Scale | None = None, # TODO or always have a Scale?
) -> LookupMapping:

values = self._provided
values = self._values
order = None if scale is None else scale.order
levels = categorical_order(data, order)

Expand Down Expand Up @@ -378,7 +378,7 @@ def __init__(self, shapes: list | dict | None = None, variable: str = "marker"):
elif isinstance(shapes, dict):
shapes = {k: MarkerStyle(v) for k, v in shapes.items()}

self._provided = shapes
self._values = shapes
self.variable = variable

def _default_values(self, n: int) -> list[MarkerStyle]:
Expand Down Expand Up @@ -443,7 +443,7 @@ def __init__(
elif isinstance(styles, dict):
styles = {k: self._get_dash_pattern(v) for k, v in styles.items()}

self._provided = styles
self._values = styles
self.variable = variable

def _default_values(self, n: int) -> list[DashPatternWithOffset]:
Expand Down

0 comments on commit 966218f

Please sign in to comment.