https://kotlinlang.org logo
Title
i

Igor Alshannikov

01/18/2021, 9:34 PM
a

altavir

01/19/2021, 7:34 AM
Nice. I am eagerly waiting for normal kotlin API
Also I am missing zoom feature from Plotly.
i

Igor Alshannikov

01/19/2021, 5:56 PM
We are planning zoom but not in the nearest feature. How does one zoom in Plotly?
a

altavir

01/19/2021, 5:57 PM
By drawing a rectangle with LMB
i

Igor Alshannikov

01/19/2021, 5:58 PM
And zoom-out by drawing a rect in opposite direction?
a

altavir

01/19/2021, 5:59 PM
In Plotly double click resets the zoom and it is convinient. When I had time to play with my own implementations over JFC, I also have done a dynamic detai feature. The idea is that if you have too many data points on the plot, you randomly select only some points and show them. Then, if you enlarge the region, additional points are loaded from the data source to keep detail in selected region constant.
i

Igor Alshannikov

01/19/2021, 6:03 PM
Yes, this is useful feature.
a

altavir

01/19/2021, 6:04 PM
It imposes limitations on the data source though. It must support dynamic loading. Not very hard to implement in Kotlin, but it requires some design effort.
h

holgerbrandl

01/21/2021, 3:24 PM
@Igor Alshannikov great work! A conceptual enhancement would be to include categorical variables as well. See https://stackoverflow.com/questions/52554336/plot-the-equivalent-of-correlation-matrix-for-factors-categorical-data-and-mi/56485520#56485520 for an R example. i find these mixed association/correlation analysis very useful when doing EDAs.
What's the intent of
%useLatestDescriptors
?
i

Igor Alshannikov

01/21/2021, 4:16 PM
It tells the kernel to ignore the installed library descriptors and pull the latest library descriptors from git. Of course,I wanted the latest for this demo.
@holgerbrandl Thanks for the support and this improvement idea! - I've saved it for future - https://github.com/JetBrains/lets-plot/issues/295
👍 1
h

holgerbrandl

01/21/2021, 5:21 PM
Just out of curiosity, why did you share the notebook via nbviewer.jupyter.org and not directly the github link? Is the github ipynb renderer less suited to render kotlin-kernel notebooks?
i

Igor Alshannikov

01/21/2021, 6:01 PM
By direct github link the plots in demos won't show up because github ipynb viewer does not execute javascript. This is not related to kotlin-kernel, I do the same with Python demos as well.
a

altavir

01/21/2021, 6:04 PM
This actually is partially a problem of kotlin kernel since there are limitation on what could be embedded in the page and @Ilya Muradyan is trying to overcome some of them. I think it is possible to embed images and make them visible in gist/github, but it requires a lot of work to implement and test.
i

Igor Alshannikov

01/21/2021, 7:01 PM
True but not related to @holgerbrandl question. Any static output like html with img tag will work with github's viewer just fine. The issue only arises when output contains javascript. Such output won't work.
h

holgerbrandl

01/21/2021, 7:02 PM
Thanks for sharing