daru-view
daru-view copied to clipboard
Error When Using Highcharts / Googlecharts
Hi, when I try to use another plotting library other than the default I get an error.
Example:
require 'daru/view'
Daru::View.plotting_library = :googlecharts
df = Daru::DataFrame.new(
{'Names' => %w(A B C), 'Data' => [2,3,5]}
)
Daru::View::Plot.new(df, {type: :bar, x: 'Names', y: 'Data'})
The error is:
NoMethodError
(undefined method `access_row_tuples_by_indexs' for #<Daru::DataFrame:0x00005598eae589f8>)
I'm using:
- Daru 0.2.1
- Daru-View 0.2.4
- Ruby 2.5
Hi @matugm,
Thanks for letting us know. Please use "daru" version '0.2.0' or the latest one from the SciRuby/daru.
Hi @Shekharrajak,
Thanks for your reply!
If I understand correctly daru-view is going to be merged as part of daru itself?
What's left to do? Is there a roadmap?
daru-view is plugin gem to daru, having lots of visualization features. You can go through this details and read more about the plans in daru-view/wiki/idea .
It will not be merged in daru repository. It can work independently.
Please let me know if you find any issue.
@Shekharrajak , I don't know where the problem lies here, this works fine in Jupyter Notebook Viewer, but is throwing the above mentioned error on my local iruby notebook in the 10th, 13th, 14th ,15th ,21st and 22nd cell . Will try to find the bug.
@snpd25 It looks like you are using older version of daru. Follow the comment https://github.com/SciRuby/daru-view/issues/130#issuecomment-451206643
@Shekharrajak, I am using "daru" version '0.2.1' .
@snpd25 , Uninstall daru and daru-view gem from your system and install daru-view gem from github source. Let me know if you still having the same issue.
I tried it, but the error persists.
ping @Shekharrajak
Can you share some details like gem list daru remove it and install it again gem install daru-view (0.2.5 version which has more fixes).
@Shekharrajak
*** LOCAL GEMS ***
daru (0.2.1, 0.2.0)
daru-data_tables (0.3.5)
daru-view (0.2.5)
bundle installs daru 0.2.0
Ruby 2.5.1
daru (0.2.1, 0.2.0)
Can you remove daru 0.2.1 version and try ?
Oh yes, @Shekharrajak , It works. But should we try to make it compatible with the latest version of daru as well? Just a suggestion. Thanks!
Oh yes, @Shekharrajak , It works. But should we try to make it compatible with the latest version of daru as well? Just a suggestion. Thanks!
I think, if you remove the 0.2.0 instead of 0.2.1, then also it will work.
Nope, it doesn't work with that and throws this warning:
Could not load bundler: Could not find daru-0.2.0 in any of the sources
Please let me know what commands you run.
I uninstalled daru 0.2.0 using gem uninstall daru and then I installed daru 0.2.1.
After that I started iruby notebook.
I uninstalled daru 0.2.0 using
gem uninstall daruand then I installed daru 0.2.1. After that I startediruby notebook.
I didn't understand how running iruby notebook will return Could not load bundler: Could not find daru-0.2.0 in any of the sources
It appeared in the terminal.