Numo::NArray - New NArray class library for Ruby/Numo (NUmerical MOdule)
under development
Related Projects
- Numo::Linalg - Linear Algebra library with LAPACK.
- Numo::GSL - Ruby interface for GSL (GNU Scientific Library).
- Numo::FFTE - Ruby interface for FFTE (A Fast Fourier Transform library with radix-2,3,5).
- Numo::Gnuplot - Simple and easy-to-use Gnuplot interface.
Installation
Ubuntu, Debian
apt install -y git ruby gcc ruby-dev rake make
git clone git://github.com/ruby-numo/narray
cd narray
gem build numo-narray.gemspec
gem install numo-narray-0.9.0.2.gem
Quick start
An example
[1] pry(main)> require "numo/narray"
=> true
[2] pry(main)> a = Numo::DFloat.new(3,5).seq
=> Numo::DFloat#shape=[3,5]
[[0, 1, 2, 3, 4],
[5, 6, 7, 8, 9],
[10, 11, 12, 13, 14]]
[3] pry(main)> a.shape
=> [3, 5]
[4] pry(main)> a.ndim
=> 2
[5] pry(main)> a.class
=> Numo::DFloat
[6] pry(main)> a.size
=> 15
For more examples, check out this narray version of 100 numpy exercises.
Documentation
All documents are primitive.
- Numo::NArray API Doc
- Numo::NArray概要 (in Japanese)
- Numo::NArray vs numpy