Hello world plot

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Hello world plot

Joseph Wang-2
I got a hello world plot that interfaces QuantLib with tvtk

I was wondering if there are any volumetric quantities in QuantLib that would
be worth ploting?


Running with ipython -wthread


import scipy
import numpy
import QuantLib

# prepare some interesting function:
surface = QuantLib.TestSurface()

x = scipy.arange(-7., 7.05, 0.1)
y = scipy.arange(-5., 5.05, 0.1)

# 3D visualization of f:
from enthought.tvtk.tools import mlab
fig = mlab.figure()
s = mlab.SurfRegular(x, y, scipy.vectorize(lambda x, y:surface(x,y)))
fig.add(s)



--
-------------------------------------------------------------------------------
Joseph Wang Ph.D. - [hidden email]  
China Derivatives Researcher and Software Developer - QuantLib
http://en.wikiversity.org/wiki/User:Roadrunner





-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev

test.jpg (41K) Download Attachment