Open Shekharrajak opened 7 years ago
Ping @michelson
Hi @Shekharrajak, I've never used IRuby , but I believe that the output is just "stringyfing" the object, that's why you are getting that.
You have to use the view helper in order to output the proper content, using high_chart("my_id", @chart)
take a look at the dummy apps , https://github.com/michelson/lazy_high_charts/blob/master/spec/dummy_nanoc/lib/default.rb
cheers!
Thanks @michelson for sharing the link.high_chart
returns the script and div part for the webpage, but I think there is need of dependent script means these scripts :
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="http://code.highcharts.com/highcharts.js"></script>
<!-- for 3d plotting -->
<script src="https://code.highcharts.com/highcharts-3d.js"> <script>
<script src="https://code.highcharts.com/modules/exporting.js"> </script>
to view the chart.
Hi @Shekharrajak , Yes it does!
check the layout file in the nanoc dummy app, it has the following scripts in order for the HC script to work
do you need more help ? should we close this ?
@michelson , I see dummy app and usage of high_chart
and tried in IRuby notebook. I tried IRuby.display high_chart("some_id", chart), mime: 'text/html'
which returns nothing.
I think, when we require the gem in iruby notebook , it must load the dependent scripts/js files that will be used in high_chart
generated html code to display the charts in notebook.
I want to see plots in IRuby notebook.
When I do
I get this
But I want to see the chart instead. What should I do for display charts ?