Brief Overview and Introduction
Currently, the Python Quant Platform is in beta/pre-release mode and is developed and maintained by The Python Quants GmbH. It offers Web-/browser-based data and financial analytics for individuals, teams and organizations. Free registrations are possible under http://beta.quant-platform.com.
Please note that trial/test accounts are only for illustration purposes and they can be closed at any time (with all data, code, etc. be permanently deleted).
If you have questions about the platform or any troubles, you can reach us under firstname.lastname@example.org.
At the moment, the Python Quant Platform comprises the following components and features:
In the left panel of the platform, you find the current working path indicated (in black) as well as the current folder and file structure (as links in purple). Note that in this panel only IPython Notebook files are displayed. Here you can navigate the current folder structure by clicking on a link. Clicking on the double points ".." brings you one level up in the structure. Clicking the refresh button right next to the double points updates the folder/file structure. Clicking on a file link opens the IPython Notebook file.
You find a link to open a new notebook on top of the left panel. With IPython notebooks, like with this one, you can interactively code Python and do data/financial analytics.
print ("Hello Quant World.")
Hello Quant World.
# simple calculations 3 + 4 * 2
# working with NumPy arrays import numpy as np rn = np.random.standard_normal(100) rn[:10]
array([-0.32688652, 0.79683012, 0.41564703, 0.5784685 , -0.22102602, -0.56581669, -0.06886181, -1.30672687, 0.51128603, 1.05541293])
# plotting import matplotlib.pyplot as plt %matplotlib inline plt.plot(rn.cumsum()) plt.grid(True)
Combining the pandas library with IPython Notebook makes for a powerful financial analytics environment.
import pandas as pd import pandas.io.data as web
AAPL = web.DataReader('AAPL', data_source='google') # reads data from Google Finance AAPL['42d'] = pd.rolling_mean(AAPL['Close'], 42) AAPL['252d'] = pd.rolling_mean(AAPL['Close'], 252) # 42d and 252d trends
AAPL[['Close', '42d', '252d']].plot(figsize=(10, 5))
<matplotlib.axes.AxesSubplot at 0x7f6d9afd2b90>
DX Analytics is a Python library for advanced financial and derivatives analytics written by The Python Quants. It is particularly suited to model multi-risk derivatives and to do a consistent valuation of portfolios of complex derivatives. It mainly uses Monte Carlo simulation since it is the only numerical method capable of valuing and risk managing complex, multi-risk derivatives books.
import dx %run dx_example.py # sets up market environments # and defines derivative instrument
max_call.payoff_func # payoff of a maximum call option # on two underlyings (European exercise)
"np.maximum(np.maximum(maturity_value['gbm'], maturity_value['jd']) - 34., 0)"
max_call.vega('jd') # numerical Vega with respect # to one risk factor
We are going to generate a Vega surface for one risk factor with respect to the initial values of both risk factors.
asset_1 = np.arange(28., 46.1, 2.) asset_2 = asset_1 a_1, a_2 = np.meshgrid(asset_1, asset_2) value = np.zeros_like(a_1)
%%time vega_gbm = np.zeros_like(a_1) for i in range(np.shape(vega_gbm)): for j in range(np.shape(vega_gbm)): max_call.update('gbm', initial_value=a_1[i, j]) max_call.update('jd', initial_value=a_2[i, j]) vega_gbm[i, j] = max_call.vega('gbm')
CPU times: user 5.44 s, sys: 2 ms, total: 5.44 s Wall time: 5.44 s
dx.plot_greeks_3d([a_1, a_2, vega_gbm], ['gbm', 'jd', 'vega gbm']) # Vega surface plot
The File Manager allows the easy, GUI-based file management on the platform.
In the left column you can navigate the file system. For instance, you find a folder called
public which you can use to share files with others.
In the right column, you find the contents of the folder currently active in the left column. The content is updated by clicking on the refresh butotn. You can, for example, drag and drop files and folders as well as upload files from you local disk. For uploading, you have to do the following:
Via a double click on a file, you can download it. In addition, via a right click on a file, you can:
All file operations are only implementable based on the respective user's rights on the operating system level. For example, everybody can copy a file to the
public folder. This file can then be read and executed by everybody, but only the "owner" of the file can overwrite or delete it.
This component of the platform allows the shell-based access to the Linux server. This part of the platform requires a separate login for security reasons (credentials available upon request).
For example, you can also interactively code on the shell via IPython Shell. The IPython Shell version is started by simply typing
ipython in the system shell.
Via the system shell you can of course edit and kind of text document and file with computer code, e.g. Python. To this end, you can use Vim which is started via typing
vim filename on the system shell or alternatively Nano (started by
Of course, you can do anything else via the system shell given your personal rights on the operating system level. Among others, you can:
The Python Quants group – i.e. The Python Quants GmbH, Germany, and The Python Quants LLC., New York City – provide consulting and development services with a focus on Python for Finance. The team consists of Python and Financial experts with comprehensive experience in the financial industry and in particular in the Quant Finance space.
For example, The Python Quants have designed and implemented a Python-based Tutorial for Eurex, one of the leading derivatives exchanges in the world. The tutorial is about volatility derivatives and is called VSTOXX Advanced Services and is available under http://www.eurexchange.com/vstoxx/. There are is also strategy backtesting application available under http://www.eurexchange.com/vstoxx/app2/
The Python Quants group offers trainings on a global basis. Training offerings include, among others:
During trainings, the Python Quant Platform is used for a frictionless start and a highly interactive, collaborative training experience.
from IPython.display import HTML HTML('<iframe src=http://quantshub.com/content/python-finance-yves-j-hilpisch width=90% height=300></iframe>')
There are two books available from The Python Quants group about Python for Quant Finance.
The other book by The Python Quants group is about advanced, market-based derivatives analytics and uses Python to illustrate and implement all numerical methods introduced (Fourier-based option pricing, Monte Carlo simulation, option model calibration, hedging).
The book will be published in 2015 by Wiley Finance.
The Python Quants also organize the largest "For Python Quants" conference in the world. At the recent NYC conference in March 2014, more than 220 people have been in attendance (cf. http://forpythonquants.com). The next one will take place in London on 28. November 2014.
Please contact us if you have any questions or want to get involved in our Python community events.