Skip to content

Using the mark sort option excludes other marks' values from sorted domain #2440

Description

@mootari

I'm filing this bug with the caveat that it might be expected behavior.

Given two marks that render different sets of values, if the first mark defines a sort option then the sorted domain won't include the second mark's channel values.

The following example:

Plot.plot({
  marks: [
    Plot.dot([{k: "b", v: 1}, {k: "a", v: 2}], {x: "v", y: "k", sort: {y: "x"}}),
    Plot.dot([{k: "b", v: 1}, {k: "c", v: 3}], {x: "v", y: "k"}),
  ],
})

extends x to include {k: "c", v: 3} but does not extend y:

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn’t working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions