Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What's the function to adjust the labels on xAxis to fit in canvas better? #5

Open
happyshows opened this issue Mar 26, 2015 · 3 comments

Comments

@happyshows
Copy link

I tried to use set_bounds to expand the space to allow it automatically fit in, but I'm not sure whether it's the right thing to do.

@timelyportfolio
Copy link
Owner

set_bounds is the correct method of placing the graph within the SVG container. Note, you can use both percentage value and/or integers (in px).

@happyshows
Copy link
Author

k thanks. What's the function to set the dimension of SVG container? It seems that container starts to trim canvas when height pass 360px?

@timelyportfolio
Copy link
Owner

height and width parameters control the size of the dimple container. Below 400 px you'll probably start seeing some clipping, but for the example below 200 even works.

library(rcdimple)

dimple(
  data = data.frame(name = rownames(mtcars), mtcars )
  , mpg ~ hp
  , groups = c("name", "cyl")
  , type = "bubble"
  , xAxis = list( type = "addMeasureAxis" )
  , height = 200
  , width = 200
)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants