erblast / parcats Goto Github PK
View Code? Open in Web Editor NEWhtmlwidget that creates plotly parallel categories diagrams from easyalluvial plots.
Home Page: https://erblast.github.io/parcats/
License: Other
htmlwidget that creates plotly parallel categories diagrams from easyalluvial plots.
Home Page: https://erblast.github.io/parcats/
License: Other
When plotting a treemap graph and a parcats graph in a RMarkdown document, the former does not display because the parcats library references plotly.js version 1.47.3 which does not support treemap traces.
library(plotly)
library(easyalluvial)
library(parcats, attach.required = FALSE)
df1 = read.csv('https://raw.githubusercontent.com/plotly/datasets/718417069ead87650b90472464c7565dc8c2cb1c/sunburst-coffee-flavors-complete.csv')
df2 = read.csv('https://raw.githubusercontent.com/plotly/datasets/718417069ead87650b90472464c7565dc8c2cb1c/coffee-flavors.csv')
fig <- plot_ly(
type='treemap',
ids=df1$ids,
labels=df1$labels,
parents=df1$parents,
domain=list(column=0))
fig <- fig %>% add_trace(
type='treemap',
ids=df2$ids,
labels=df2$labels,
parents=df2$parents,
maxdepth=1,
domain=list(column=1))
fig <- fig %>% layout(grid=list(columns=2, rows=1))
fig
p = alluvial_wide(mtcars2, max_variables = 5)
parcats(p, marginal_histograms = FALSE)
Is thera a way to change the plotly.js version reference?
After playing with my alluvial plot, I would like to save it as a png. But the resulting image is very small (700 x 450). I would have liked to use plot_ly() config arguments (https://plotly-r.com/exporting-static-images.html) such as:
plot_ly() %>% config( toImageButtonOptions = list( format = "svg", filename = "myplot", width = 600, height = 700 ) )
But these have no effect on a paracats object... Could this be incorporated or an option to set the size of exports of paracts objects directly?
Dear @erblast,
I really enjoy your packages and am currently trying to extend some hover options (which you already started).
As i am still new to plotly, i am currently stuck with some questions and was wondering if you could point me to the respective code junks where they are to solve.
As shown above, i extended hovertemplate but would like to populate it with other data like "count".
I could not find "count" being initiated in the repo. Could you point me to it so i could extend it to other data variables?
Or is this coded in the plotly.js?
Of course, all code will be pushed to your repo if you agree to.
Thank you,
michel
Hi, I got a problem. I don't know why alluvial diagram will be overlap in the same place when I use the parcats-shiny?
What should I do about it?
The shiny app is on https://github.com/xiaowei3223/git_issues/tree/main/issues_for_parcats
Hi,
Iโm successfully using your libraries parcats and easyalluvial.
Simple question: how to save pdf or eps file?
thanks
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.