Financial Applications of MATLAB

Our course on MATLAB

Join our MATLAB for financial engineering course (http://www.wiziq.com/course/7225-matlab-for-financial-engineering) & get 15% discount. Ask for discount code, email - info@qcfinance.in

Websitehttp://qcfinance.in/

In this post I am going to talk about how to use MATLAB for Financial Risk Management. Also for Fixed Income in general. There is a big file of fixed income of 500 pages which MATLAB has provided.

1. For those who have not done Programming before the logical flow like For statement becomes the first Hurdle.
2. Regression using MATLAB.
3. Symbolic computations.
4. Making Chart: Polyval(c,x) to make the long elements that can be then used for making chart.
5. Different way to make different type of matrix, like equal, incremental etc.
6. Matrix division vs Element by element division.
Program 1: Consider writing a user-deﬁned function that searches a matrix input argument for the element with the largest value and returns the indices of that element.

Book Review: MATLAB Basics and Beyond: This book has lot of graphic and graphics and data type forms the heart of stuff that are done.

Book Review: MATLAB Primer

FRM Level 2 terms in MATLAB Stat toolbox:
• Copula
• Modelling Tail Data with the Generalized Pareto Distribution.
• Modelling Data with the Generalized Extreme Value Distribution.
• Bayesian Analysis for a Logistic Regression Model.
• Weibull distribution.

Data Cleaning and management with MATLAB:
1. Playing with Array & Matrix.
2. Errors and data cleaning Excel.
3. Programs you have made on VBA.
4. Old programs in MATLAB (questions on that).
5. Movement and arrays of data.
6. Time series analysis in MATLAB.
7. Types of array / matrix / data types / vector arrays etc.
8. Reducing and selecting of Matrix.
9. Looping for data handing in Excel.
10. Reading Data from SQL Database and linking the system (advanced and out of scope), MATLAB Database toolbox.
11. Interpretation and Control.
12. Trading MATLAB and importance of Visualization.
14. SAS vs MATLAB for Intermediary display.
15. CDS MATLAB / VAR 99% VAR 1 day, this is interesting probability of default as well, bond valuation in MATLAB using some data.
16. Loops for Array.
17. CDS in MATLAB, article of Markit.
18. Query Builder SQL Array.
19. Struct http://www.mathworks.in/help/techdoc/ref/struct.html.

There was array handing, and how to manage data for Quant Finance...

Preparing data for final analysis for: Algo trading & VAR computations

Five area of MATLAB you need to master:
1. StatisticalToolbox
2. Symbolic computation toolbox
3. Fixed income
4. Econometrics (Monte Carlo)
5. Derivatives
Generic Knowledge about the industry needed:
• Data -- Inter-phasing -- Output
• Bank Rating Consumer
• Shorting CDS
• Causes and Role of Goldman on Greece Crisis

Interesting areas in MATLAB Finance where I am researching solutions are:
1. Data management or data cleaning or data optimization skills used in MATLAB.
2. Loop for data correction like addressing blank or data types management.
3. Optimizing data for time series.
Three job profiles:
1. Bond spreads, CDS, fixed income etc (M).
2. VAR, PoD, bond portfolio, companies bond, trading data and VAR for that, etc (G).
3. Data cleaning for Time series, other data cleaning and optimizations (E).

References:
http://www.mathworks.in/help/techdoc/ref/struct.html
http://www.mathworks.in/help/techdoc/ref/size.html
http://www.mathworks.in/help/techdoc/ref/f16-42340.html
http://www.mathworks.in/products/matlab/demos.html?file=/products/demos/shipping/matlab/nddemo.html

MATLAB for Finance by qcfinance.in

This article will talk about various applications in MATLAB for finance. We have taken in real time issues in the recent months and discussed how we can simulate some on them on MATLAB.

MATLAB can be learned and used for all of the following purposes:
1. Old work ppt: Reliability, HPC, simulink etc.
2. Data cleaning, data modifications, data arrays, struct, rating matrix, selection of elements from rating matrix, banks internal rating and pod computations, post that you made.
3. Matlab for game theory.
4. For fixed income Bond pricing, CDS, and other leveraged fixed income tools on MATLAB.
5. Matlab for distributions and monte carlo.
6. Data handing from sql and other parameters for MATLAB.
7. MATLAB HPC toolbox to be used for various other options.
8. Neural network in Finance.
There were few articles I found on MATLAB Credit Risk and there were many more on their website:
http://www.mathworks.in/products/finance/

Conclusion
• MATLAB Credit Risk : Credit Risk Modeling Using Excel and VBA is a good book to look out for excel based modeling which then can be taken into MATLAB (link was on the references of the above articles)
• As far as the comparison goes, R vs MATLAB, MATLAB is much easier and the only reason people do R in west is because R is free and MATLAB is very expensive.
• As per my knowledge R and SAS are not so much user friendly, although when it comes to hardcore data handling SAS is much much better. MATLAB is good for easier applications.
Quantitative Analysis & Fixed Income Research:
1. Back-testing of investment strategies.
2. Credit risk modelling using KMV approach (Merton Model), there is a tool of Moodies, and also work on Municipal bonds (question in interivews).
3. Monte-Carlo simulation.
4. Portfolio optimization and asset allocation.
5. Statistical modelling, variance-covariance modelling, value at risk modelling, regular risk reporting (hot spot reports, concentration reports), risk assessment and style analysis of money managers, term structure modelling, rich cheap analysis.
6. Mark-to-market of fixed income instruments.
7. Credit research reports covering liquidity and debt analysis (Equity based).
Thus looking at them can help us understand how MATLAB can help us to work on these specific areas.

Passive Smart ETF

CMO

http://www.mathworks.in/help/fininst/using-collateralized-debt-obligations-cmo-.html

http://www.mathworks.in/help/fininst/cmoschedcf.html
http://www.mathworks.in/help/fininst/mbscfamounts.html
http://www.mathworks.in/help/fininst/cmoseqcf.html
http://www.mathworks.in/help/fininst/example-collateralized-debt-obligations-cmos-.html
http://en.wikipedia.org/wiki/Collateralized_mortgage_obligation

statistical_toolbox.pdf
econometrics_toolbox.pdf
financial_derivatives_toolbox.pdf
financial_time_series_toolbox.pdf
fixed_income_toolbox.pdf
financial_toolbox.pdf

Some Books to refer:
• Elementary Stochastic Calculus With Finance in View (Advanced Series on Statistical Science & Applied Probability, Vol 6) (Advanced Series on Statistical Science and Applied Probability).
• Financial Options: From Theory to Practice.
• Paul Wilmott on Quantitative Finance 3 Volume Set (2nd Edition).
• Monte Carlo Methodologies and Applications for Pricing and Risk Management.
• Stochastic Calculus for Finance I: The Binomial Asset Pricing Model (Springer Finance / Springer Finance Textbooks).
• Modern Pricing of Interest-Rate Derivatives: The LIBOR Market Model and Beyond.
• The Analysis of Structured Securities: Precise Risk Measurement and Capital Allocation.
• Credit Derivatives Pricing Models: Models, Pricing and Implementation (The Wiley Finance Series).

Uploaded by Shivgan on WizIQ Tutorials

One on One Customized Training:
qcfinance.in believes in personalized touch so that our clients are completely satisfied with our service. In this regard, we offer One on One Customized Training to our clients.
These Training are provided on requests by our clients & are customized according to their individual needs.
The course structure & timings for these training are highly flexible, classes are scheduled as per the convenience of our clients.