??? Undefined function or method 'sparse' for input arguments of type 'int32'.

Asked by kenza gaizi

Following what has been described here: http://matlab4java.wordpress.com/faq/ I was able to convert from Java 2D array to Matlab Array (A) , however when I wanted to apply the function: test_planar_graph(sparse(A)), I got this error:

??? Undefined function or method 'sparse' for input arguments of type 'int32'.

Do you have any suggestions? I looked at mex -setup but it didn't work

Question information

Language:
English Edit question
Status:
Solved
For:
Matlab BGL Edit question
Assignee:
No assignee Edit question
Solved by:
kenza gaizi
Solved:
Last query:
Last reply:
Revision history for this message
kenza gaizi (kenza-gaizi) said :
#1

I found the solution,
I just had to do the following:

C = double (A)
test_planar_graph(sparse(C)) --> It worked fine :)