matlab-ruby 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
data/History.txt
CHANGED
@@ -231,7 +231,7 @@ class SWIG::TYPE_p_mxArray_tag
|
|
231
231
|
mxArrayToString(self)
|
232
232
|
when mxIsLogical(self)
|
233
233
|
mxIsLogicalScalarTrue(self)
|
234
|
-
when (mxGetM(self) > 1 || mxGetN(self) > 1)
|
234
|
+
when (mxGetM(self) > 1 || mxGetN(self) > 1) || (mxGetM(self) == 0 && mxGetN(self) == 0)
|
235
235
|
Matlab::Matrix.from_matlab(self)
|
236
236
|
when mxIsDouble(self)
|
237
237
|
mxGetScalar(self)
|
data/lib/matlab/version.rb
CHANGED
@@ -64,6 +64,11 @@ class ConversionsTest < Test::Unit::TestCase
|
|
64
64
|
assert_equal matrix, matrix.to_matlab.to_ruby
|
65
65
|
end
|
66
66
|
|
67
|
+
def test_should_convert_a_0x0_matlab_matrix
|
68
|
+
matrix = Matlab::Matrix.new(0, 0)
|
69
|
+
assert_equal matrix, matrix.to_matlab.to_ruby
|
70
|
+
end
|
71
|
+
|
67
72
|
def test_matlab_cell_matrix_to_matlab_to_ruby
|
68
73
|
cell_matrix = Matlab::CellMatrix.new(3, 3)
|
69
74
|
3.times { |m| 3.times { |n| cell_matrix[m, n] = (n == 1 ? rand.to_s : rand) } }
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: matlab-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jonathan Younger
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2008-
|
12
|
+
date: 2008-05-19 00:00:00 -06:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -19,7 +19,7 @@ dependencies:
|
|
19
19
|
requirements:
|
20
20
|
- - ">="
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 1.5.
|
22
|
+
version: 1.5.1
|
23
23
|
version:
|
24
24
|
description: "== USAGE: require 'matlab' engine = Matlab::Engine.new engine.put_variable \"x\", 123.456 engine.put_variable \"y\", 789.101112 engine.eval \"z = x * y\" engine.get_variable \"z\" matrix = Matlab::Matrix.new(20, 400) 20.times { |m| 400.times { |n| matrix[m, n] = rand } } engine.put_variable \"m\", matrix engine.save \"/tmp/20_x_400_matrix\" engine.close # May also use block syntax for new Matlab::Engine.new do |engine| engine.put_variable \"x\", 123.456 engine.get_variable \"x\" end == REQUIREMENTS: * MATLAB * GCC or some other compiler to build the included extension * SWIG (If you want to recompile the SWIG wrapper) * Mocha (For testing only)"
|
25
25
|
email:
|
@@ -77,7 +77,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
77
77
|
requirements: []
|
78
78
|
|
79
79
|
rubyforge_project: matlab-ruby
|
80
|
-
rubygems_version: 1.
|
80
|
+
rubygems_version: 1.1.1
|
81
81
|
signing_key:
|
82
82
|
specification_version: 2
|
83
83
|
summary: A Ruby interface to the Matlab interpreted language.
|