eenriquelopez
06/18/2025, 9:52 AMeenriquelopez
06/18/2025, 10:54 AMAndrei Kislitsyn
06/18/2025, 10:56 AMwithData()
extension for plot builder, that allows to override your plotting dataset. However, now there's a flaw - it doesn't work properly if you use for "geo plot" GeoDataFrame.plot {}
.
https://github.com/Kotlin/kandy/issues/480.
But you still use withData
in a common plot, something like this:
filteredRides.plot {
withData(munichArea) {
geoMap() {
fillColor = Color.LIGHT_BLUE
borderLine {
color = Color.PURPLE
width = 1.5
}
}
points {
x("STARTLON") { axis.name = "Longitude" }
y("STARTLAT") { axis.name = "Latitude" }
color = Color.RED
alpha = 0.5
}
points {
x("ENDLON")
y("ENDLAT")
color = Color.BLUE
alpha = 0.5
}
layout.title = "Geolocation of Start (Red) and End (Blue) Points"
}
eenriquelopez
06/18/2025, 10:57 AM