Kotlin / kandy

Kotlin plotting library.
https://kotlin.github.io/kandy/
Apache License 2.0
603 stars 16 forks source link

how to change yAxis position? #433

Closed khm0651 closed 1 month ago

khm0651 commented 2 months ago

i saw https://github.com/Kotlin/kandy/issues/306
but i cant find change yAxis position left or right in API doc i want change yAxis position left to right how can i do that??

like that python matplotlib yaxis.tick_right()

AndreiKingsley commented 2 months ago

Hi! You can do it with axis position setting (axis settings):

plot {
   // first way - in mapping configuration
   points {
        x(...) 
        y(...) {
            axis.position = AxisPosition.OPPOSITE
        }
    }
    // second way - free axis configuration
   y.axis.position = AxisPosition.OPPOSITE
}

But I just looked, it's not working right now because of a bug #434. Will fix it soon.

khm0651 commented 2 months ago

@AndreiKingsley thank you so much

AndreiKingsley commented 1 month ago

Fixed in 0.7.1.