Giter VIP home page Giter VIP logo

d3partitionr's People

Contributors

antoineguillot2 avatar csgillespie avatar keithcallenberg avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

d3partitionr's Issues

Renaming / Removing Root from the graph/Controlling colours

Hi,

I am using your package to create a visualization. However, I am not sure how to control colors,remove or rename root. It would be great if you could help me out with this.

Dataset

         Invoked_from               functionality          action  N
1: Invoked_from alpha functionality document menu      action add  1
2: Invoked_from alpha functionality document menu    action click 29
3: Invoked_from alpha functionality document menu    action close  1
4: Invoked_from alpha functionality document menu   action expand  5
5: Invoked_from alpha functionality document menu   action follow  1
6: Invoked_from alpha functionality document menu action maintain  2

d3 = D3partitionR() %>%
  add_data(pt,count = 'N',steps=c('Invoked_from','functionality','action')) %>%
  add_title('SRA') %>%
  plot()

d3

d3test

Any help would be great

Use variable width for breadcrumbs

First, thanks for these great visualizations!

I have data with sometimes long category names which leads to overwriting in the breadcrumbs trail.

image

Can you adapt the breadcrumb sizes to the string length?

Not working on mobile

Thank you for your package.

I am learning how to use it but I could not make it work on mobiles. If I save a chart (from RStudio Viewer) as html, I can not have the same behavior as in the computer when clicking on the chart.

Any suggestions?

Proposals for improvements

Hello,

I think there is a great potential in this package.

Below are a few improvements I thought of:

  • Trail: In some cases (typically when more than one D3partitionR object are displayed in a Shiny application), the trail is cut off. One solution could be to put the trail in a scrollbars environment.

  • Colors option: Would it be possible to allocate different colors to every top level (i.e. obviously not the whole but the levels just below) and then to keep this color when descending into its sub-levels and just make its luminosity vary (i.e. gradient approach)?

  • Speed: When more than one D3partitionR object are displayed in a Shiny application and when the type of graph is changed (e.g. through a drop-down menu), it can take some time (around 10 seconds on my laptop - I can give its specifications if needed). Maybe the speed could be improved?

  • Inspirations: I found the Baobab (under GNU Linux) and WinDirStat (under Windows) softwares a great source of inspiration:

  1. It could be useful (perhaps as an option?) to be able to go through the different levels in a separate window (with scrollbars as well) next to the graph with the key figures displayed on each level (see Baobab); the different selected levels would then simultaneously be highlighted on the graph. Perhaps also as an alternative to the trail.
  2. A tiny improvement proposal: regarding the colors, they could be a bit more shiny like in WinDirStat.
  • Package management: Tiny last improvement: the package 'magrittr' could be automatically (i.e. not explicitely loaded by the user) loaded with D3partitionR.

  • Reference manual: I noticed some typos (e.g. "set_continuous_color_scale
    Add a custom discrete color scale").

Best regards,

Olivier

tooltip on Shiny

Hi,

My tree works on R, and tooltips as well.
However, when using Shiny, I can't see the tooltips anymore.
Do you have any ideas of why?

D3partitionR chart not working on shiny server ,but working in shinylocally

D3partitionchart working fine in shiny locally but on shiny server I am getting the folowwing eror,please help me on this issue
Warning: Error in [.data.table: SETLENGTH() cannot be applied to an ALTVEC object.
113: [.data.table
109: split.data.table
107: df_to_nest
106: compile_D3_partitionR
105: plot.D3partitionR
103: function_list[[k]]
101: freduce
100: _fseq
99: eval
98: eval
96: %>%
95: func [/home/mykampaign/R/ShinyApps/Segmentation/server.R#25]
82: origRenderFunc
81: output$D
1: runApp
Thanks in Advance,
Manohar

Add an option to customise nodes CSS

Add a function, for instance, set_nodes_style, to modify the nodes CSS. The function could have two parameters, one to provide the style on hover and the other one to specify the basic CSS style.

Data support issue

hello, I find the add_data() [packageVersion0.5 ] just only support class(df) is "data.table" "data.frame", when class(df) is "data.frame" or "tbl_df" "tbl" "data.frame" cant't work.

Add resizing policy

Add a resizing policy, this will probably require to refactor the d3.js code.

Null values within a sequence.

HI, I am trying to use D3partionR package to graph a sequence. My sequence has areas where a shorter sequence will have NA values to fill out the data.frame for the longer sequences. For example
seq A -> seq B -> seq C -> NA -> NA
seq A -> serb -> seq C -> seq D -> seq E.

When I try to plot the partition I get this error:
'Error in if (length(nms) != n || any(nms == "")) stop("'options' must be a fully named list, or have no names (NULL)") :
missing value where TRUE/FALSE needed'

Is there a way to by pass the NAs in my data.frame?

Tooltips disappear when zooming in a level

Hello,

First many thanks to the contributors to this already great package which can only improve.

In a Shiny application, I noticed that sometimes when zooming in a level, the tooltips disappear when hovering. When zooming out back, the tooltips don't appear again.
This bug also happens to the other D3partitionR objects displayed in the same Shiny application.

[EDIT]: This bug affects the 5 types of charts currently available. The tooltips might eventually reappear by zooming in and out on other D3paritionR objects in the same Shiny application. When eventually reappearing the location of the tooltips might also be erroneous.

Best regards,

Olivier

set_continuous_color_scale

I am attempting to set_continuous_color_scale on a treemap with the code below and it produces the error visible should be a boolean

df = data.frame(Count = c(10,20,30,40),
                L1 = c("A", "A", "B", "B"),
                L2 = c("C1", "C2", "D1", "D2"),
                stringsAsFactors = FALSE)

D3partitionR() %>%
    add_data(df, count = "Count", steps = c("L1","L2"), color = "Count") %>%
    set_chart_type('treemap') %>%
    set_continuous_color_scale(c("#aabbcc", "#112233")) %>%
    plot()

I have made various attempts to set visible with set_labels_parameters, set_legend_parameters, set_tooltip_parameters and set_trail that have failed to resolve the issue.

How do I use this function (or any other method) to modify the colors? Thanks

Programatically Click Node

I would like to programatically click a node based upon an action such as a user clicking an action button. Is it possible to capture this click event via something like: $('#your_link_id').click().

Also, is it possible to embed HTML in the actual label of the node (i.e. to include a link to a website)?

Thank you!

Limiting colors to a subset of steps/levels

Is there a way to limit the number of colors to only a specified subset of the steps/levels in the data? The lowest level in my dataset has many unique values, and assigning colors to them all makes the chart look very messy.
image

When I assign a categorical variable to the color parameter to add_data, everything turns into one color.
image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.