Skip to content

Conversation

AndreiKingsley
Copy link
Collaborator

Closes #583

@AndreiKingsley AndreiKingsley marked this pull request as ready for review September 9, 2025 12:50
@Jolanrensen
Copy link
Collaborator

Jolanrensen commented Sep 9, 2025

While this looks much better already, I wonder if there's something we can do with colors, like we have for joinWith: https://kotlin.github.io/dataframe/joinwith.html

I think these could help a lot with the visualization of which values end up where. For instance, imagine a yellow dataframe and a light blue one being joined, and the resulting dataframe consisting of the yellow columns, the blue ones and green for the join column(s).
Something per-row, like in joinWith is also possible, of course. WDYT?

We could probably even use the format {} operation for this :) now that we have support for that


<!---IMPORT org.jetbrains.kotlinx.dataframe.samples.api.multiple.JoinSamples-->

Joins two [`DataFrame`](DataFrame.md) object by join columns.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

objects

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah you just copied this part from the original file

}

private fun nameAndCityToColor(name: String, city: String?): RgbColor = when(name to city) {
"Alice" to "London" ->RgbColor(242, 210, 189)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

linting


<inline-frame src="./resources/notebook_test_join_6.html" width="100%" height="500px"></inline-frame>

If mapped columns have the same name, just select join columns from the left [`DataFrame`](DataFrame.md):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm it's hard to see where the previous example ends and the new one begins. Maybe you could give them a small title?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you do exactly that below :) nice

@Jolanrensen
Copy link
Collaborator

The colors help a lot! Thanks :)
Though I still feel like some information is missing, as joins are column-centric. Maybe you could experiment with additional formatting? like text color/thickness per column and background colors for rows? just an idea

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 this pull request may close these issues.

filterJoin example missing (What is filter in join types?)
2 participants