GithubHelp home page GithubHelp logo

jeromefroe / circlepacker Goto Github PK

View Code? Open in Web Editor NEW
24.0 2.0 13.0 606 KB

R htmlwidget for circle packing visualization

Home Page: http://jeromefroe.github.io/circlepackeR/

License: MIT License

R 57.51% JavaScript 37.55% CSS 4.93%

circlepacker's Introduction

circlepackeR

R htmlwidget for circle packing visualization, for more information please visit the main page.

A big thank you to timelyportfolio for his help and major improvements.

circlepacker's People

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

Watchers

 avatar  avatar

circlepacker's Issues

Shiny feedback

I think it would be great to return the name of the bubble to the shiny's server function when the user zooms. We could then link this HTML widget to other components in shiny

line breaks with /n

Hello,
I am developing a shiny app and am using circlepackeR for a visualization. I have multiple levels and everything is working fine but it does not appear that circlepackeR supports line breaks within a circle using "/n". I am trying to input two lines of text within a single circle using the following code:

data_nested$pathString <- paste(data_nested$level1, data_nested$circle1.OI.Primary, data_nested$circle1.OI.Secondary, data_nested$circle1.FEMA, paste0(data_nested$circle1.MG.Name," ", "\nFEMA", data_nested$circle1.FEMA), sep = "/")
data_nested$value=7
data_Node <- as.Node(data_nested)
circle <- circlepackeR(data_Node, size = "value")
circle

But it still outputs the text in a single line instead of two lines. Is there anyway to create a single circle with two lines of text?

it would be better if the color could be mapped by some attributes

from the current documentation, I suppose the colors of the circles are determined by the hierarchic levels, it would be better if the colors could be mapped by a specific attributes in the data.tree structure.
Besides, if the graph could be moved by the moving of the mouse or scroll and not limited by only clicking the circles, it would be more interactive, and the overlaps of the letters problem could be somehow relieved.
whatever, still thanks a lot for wrapping a very-easy-to-use d3.js package to R!

Installation not working via devtools in RStudio

When I input the following command,
devtools::install_github("jeromefroe/circlepackeR")
into RStudio's console tool, I get the following result:

Downloading GitHub repo jeromefroe/circlepackeR@master
from URL https://api.github.com/repos/jeromefroe/circlepackeR/zipball/master
Installing circlepackeR
"C:/PROGRA1/R/R-351.1/bin/x64/R" --no-site-file --no-environ --no-save --no-restore --quiet CMD INSTALL
"C:/Users/Stacey's Laptop/AppData/Local/Temp/RtmpsnXRoy/devtools4dc44952287d/jeromefroe-circlepackeR-f0a84d5"
--library="C:/Users/Stacey's Laptop/Documents/R/win-library/3.5" --install-tests

  • installing source package 'circlepackeR' ...
    ** R
    ** inst
    ** tests
    ** byte-compile and prepare package for lazy loading
    ** help
    *** installing help indices
    converting help for package 'circlepackeR'
    finding HTML links ... done
    circlepackeR html
    circlepackeROutput html
    renderCirclepackeR html
    ** building package indices
    ** testing if installed package can be loaded
    *** arch - i386
    Error: unexpected symbol in "tools:::.test_load_package('circlepackeR', 'C:/Users/Stacey's"
    Execution halted
    *** arch - x64
    Error: unexpected symbol in "tools:::.test_load_package('circlepackeR', 'C:/Users/Stacey's"
    Execution halted
    ERROR: loading failed for 'i386', 'x64'
  • removing 'C:/Users/Stacey's Laptop/Documents/R/win-library/3.5/circlepackeR'
    In R CMD INSTALL
    Installation failed: Command failed (1)

two requested features, are they possible?

Hello, Jerome,
Thank you for your wonderful circlepackeR. I'm using this package for visualization of a big dataframe.
picture

Here are my issues:

  1. Is it possible to hide column names at first sight, and show them only if I hover mouse above the circle?
    I'm requesting this because there are too many names on the packed circle now, which overlapped the small circles.

  2. Is it possible to color the terminate circle as pie chart?
    Now all terminate circles are white. But I have some other attributes beside "size" for each leaf. If these attributes can be represented on circlepackR, that will be great!

Thank you so much!
TJ

Submission to CRAN

Please could this package be submitted to CRAN? It would be immensely useful for work.

Cannot center circlepackeR-generated plot in Shiny app

We need to center (horizontally) a circlepackeR plot on a web page in a Shiny app. None of the "usual" Shiny tricks for centering --- columns in fluidrow, etc --- seem to work. Even forcing a text-align:center in the parent <div> of the <svg> does not seem to work.

Please advise!

Adjust text size of labels in plots

Is there any way to increase or decrease the size of the text in the circlepackeR plots? I know you haven't been updating this package of late, but that would be crucial feature for this tool.

Labels overlapping

Hi,

the node labels often overlap and are unreadable.
Is there a way to avoid they overlap?

Thanks.

d3 v4 compatibility

Hello,
I'm developping a shiny app that has dependencies on d3v4 (networkD3) but I'd like to add an interactive circlepack view.
Do you plan to code a d3v4 version of your circlepackeR function ?

Two sizing questions

Hi
I have two questions about circelpackeR:
I am using circlepackeR in a shiny dashboard.

  1. How do I scale the image so that it fills a box:
    MuniRank.box1 <- box(title = p("Municipal Clusters",
    actionButton("titleBtId", "", icon = icon("refresh"),
    class = "btn-xs", title = "Click to Expand")), width=3, solidHeader = TRUE, renderCirclepackeR(MuniPack))
    "MuniPack" is the circlepackeR visualization. How do I scale the image so that it fills the box?

  2. How do you resize the image?
    I want to expand the width of the box (so that it covers the 12 column space) and have the image resize (and make the labels in the inner circles more legible). How can I do this?

Thanks
AB

Can the subsets be shown as venn diagrams?

This is a great library. I really use it a lot in my visualizations. Thank you for this.

Could you integrate this to a more of a overlapping venndiagram inside the circles.

Thanks

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.