You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Machine Learning & Data Mining with JRuby based on the
Weka Java library.
Installation
Add this line to your application's Gemfile:
gem'weka'
And then execute:
$ bundle install
Or install it yourself as:
$ gem install weka
Usage
Use Weka's Machine Learning and Data Mining algorithms by requiring the gem:
require'weka'
The weka gem tries to carry over the namespaces defined in Weka and enhances
some interfaces in order to allow a more Ruby-ish programming style when using
the Weka library.
The idea behind keeping the namespaces is, that you can also use the
Weka documentation for looking up
functionality and classes.
Please refer to the gem’s Wiki
for detailed information about how to use weka with JRuby and some examplary
code snippets.
Development
Check out the repo with git clone git@github.com:paulgoetze/weka-jruby.git.
Set a local environment variable export JARS_VENDOR=false. This will
prevent compiling the jars into your repo’s /lib directory and will load them
from your local maven repository instead. See the
jar-dependencies README
for more information.
Run bin/setup or bundle install to install the dependencies.
Then, run rake spec to run the tests. You can also run bin/console or
rake irb for an interactive prompt that will allow you to experiment.
Create your feature branch (git checkout -b feature/my-new-feature develop)
Commit your changes (git commit -am 'Add some feature')
Push to the branch (git push origin feature/my-new-feature)
Create a new Pull Request
Please try to add RSpec tests along with your new feature. This will ensure that
your code does not break existing functionality and that your feature is working
as expected.
We use Rubocop for code style
recommendations. Please make sure your contributions comply with the project’s
Rubocop config.
Acknowledgement
The original ideas for wrapping Weka in JRuby come from
@arrigonialberto86 and his
ruby-band gem. Great thanks!
License
The gem is available as open source under the terms of the
MIT License.