JNumeric is a collection of extension modules to provide high-performance multidimensional numeric arrays to the Python programming language. This package closely follows NumPy CPython package which is described in NumPy Tutorial. There is a however a number of differences discussed below. Since JNumeric is implemented in Java, you can access Java libraries.
Here is a simple example how to with arrays:
Let us find all packages of JNumeric:
>>> import jnumeric >>> dir(jnumeric)
As example, consider “JNumeric” that provides high-performance arrays:
>>> from jnumeric.JNumeric import * >>> a = array(10) >>> b = array( [[1,0],[0,1]]) >>> print b
Print methods associated with array a as:
SCaVis allows to interface JNumeric fast arrays with other Java classes and graphical canvases for plotting similar to CPython when interfacing NumPy with MathPlot.
For example, this script generate two arrays, transform them to sqrt() (for X) and exp() (for Y) and plot on interactive canvas:
We use the Java classes
jhplot.HPlot to perform this task: