Create an account

Very important

  • To access the important data of the forums, you must be active in each forum and especially in the leaks and database leaks section, send data and after sending the data and activity, data and important content will be opened and visible for you.
  • You will only see chat messages from people who are at or below your level.
  • More than 500,000 database leaks and millions of account leaks are waiting for you, so access and view with more activity.
  • Many important data are inactive and inaccessible for you, so open them with activity. (This will be done automatically)


Thread Rating:
  • 581 Vote(s) - 3.54 Average
  • 1
  • 2
  • 3
  • 4
  • 5
What is your preferred way to produce charts in a Ruby on Rails web application?

#21
There's also [Scruffy][1]. I took a look at the code recently and it seemed easy to modify/extend. It produces svg and (by conversion) png.


[1]:

[To see links please register here]

Reply

#22
This isn't specifically RoR however, it is pretty slick port of Gruff to javascript:

[To see links please register here]

Reply

#23
I've used Fusion Charts extensively from within a Java web application, but it should work the same way from Rails since you're just embedding a Flash via HTML or JavaScript and passing it XML data. It's a slick package and their support has always been very responsive.
Reply

#24
If you don't need images, and can settle on requiring JavaScript, you could try a client-side solution like the jQuery plugin [flot][1].


[1]:

[To see links please register here]

Reply

#25
In the old days, I decided to roll my own (using RVG/RMagick), mainly because Gruff didn't have everything I wanted. The downside was that finding and eliminating all the bugs in graphing code is a pain. These days Gruff is my choice as it's really gone forward in terms of customization and flexibility.

The standard Gruff templates/color choices suck though, so you'll need to get your hands dirty for best results.
Reply

#26
I've just found [ZiYa][1] produces some really sexy charts and is Rails specific.

The downsides are it uses Flash and if you don't want the sites to link to XML/SWF page it costs $50 per site.

[I've not decided on it yet, but wanted to throw it out there in case people want to vote it up]

[1]:

[To see links please register here]

Reply

#27
We do this by shelling out to gnuplot to generate the charts as PNGs server-side. It's a bit old-school and the charts aren't interactive but it works and is cacheable.

(The other reason we do this is so we can put exactly the same chart in the PDF version of the report).
Reply

#28
I am a fan of [Gruff Graphs][1], but [Google Charts][2] is also good if you don't mind relying on an external server.


[1]:

[To see links please register here]

[2]:

[To see links please register here]

Reply

#29
[Google Charts](

[To see links please register here]

) is an excellent choice if you don't want to use Flash. It's pretty easy to use on its own, but for Rails, it's even easier with the [gchartrb](

[To see links please register here]

) gem. An example:

GoogleChart::PieChart.new('320x200', "Things I Like To Eat", false) do |pc|
pc.data "Broccoli", 30
pc.data "Pizza", 20
pc.data "PB&J", 40
pc.data "Turnips", 10
puts pc.to_url
end
Reply

#30
Google charts is very nice, but it's not a rails only solution. You simple use the programming language of your choice to dynamically produce urls that contain the data and google returns you back a nice image with your chart.

[

[To see links please register here]

][1]


[1]:

[To see links please register here]

Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

©0Day  2016 - 2023 | All Rights Reserved.  Made with    for the community. Connected through