flow
flow copied to clipboard
Clickable charts?
When we output html with svg = TRUE we can select text. If we can do that there might be a way to change this text to a hyperlink . I have no idea how that would work (post process the html file?) but for package doc this would have great value for instance.
hi, thats a good idea ;)
btw how i can zoom in to the image details? I have a problem that the function is quite long and i cant read it in the viewer., also saved it to .png but the resolution is poor and i cant see the text.
Hi, have you tried out = "pdf"
or out = "html"
? If it doesn't work out please open a separate issue and provide an example of a problematic function so I can reproduce it on my side.
thanks, yes, i found it in the function description and it worked out with out = example.png
If i got it right the function displays if
and for
and related chunks of code. Would it be possible to add more shapes for different elements of a function (for example: data, transforming tables, training model)?
@joint-hubs it might be possible, everything that can be done with diagrams to understand code better is in scope for this package. I'd need more details and examples though, can you open a dedicated issue for those ? It's better to keep the discussions focussed on a the given topic (clickable charts in this case) to be able to track progress and make it easier for users and contributors to find their way.
See https://github.com/cynkra/dm/issues/1153 for dm/DiagrammeR solution (WIP). We can probably do the something similar.
We need to investigate:
- Clickable nodes
- Clickable words
1st step is to detect click / hover and display something 2nd step is more advanced dynamic diagrams Among 2nd step is jumping from diagram to diagram, and folding/unfolding. Folding/unfolding is technically possible without server input, we can store all children in a node and have a nested structure, but that's probably more xml manipulation that what I'm ready to do.