This code is simple version of gensim library demo. Download BBC data set and unzip to a folder. Run the following code and find top 10 matched document based on your query.

This code is simple version of gensim library demo. Download BBC data set and unzip to a folder. Run the following code and find top 10 matched document based on your query.

Download Twitter data for the above code:TwitterData_RediPhone_part2

Shiny R code for multiple plots using ggplot2 and gridextra Sample code to use shiny for multiple graphs in same plot Use ggplot2 and gridextra

Risk-Neutral Skewness and Kurtosis: See this post for R code to calculate model free implied volatility. Let stock price return for period is given by: (1) The price of the volatility contract: (2) The price of the cubic contract: (3) The price of the quadratic contract: (4) Define : (5) For -period model-free implied volatility (MFIV) is: (6) […]

The code below can download daily bhav for Futures and Options from the NSE website. I have also include sample code that downloads indices level from the National Stock Exchange

The new fama-french model replaces the existing five-factor model. The new five-factor fama-french model includes profitability and investment factors. Profitability factor: Robust minus weak operating profit (RWA )= (SR + BR) / 2 – (SW + BW) / 2 = [(SR – SW) + ( BR – BW)] / 2 Investment factor: Conservative minus aggressive Investment (CMA) = (SC + BC) / 2 – (SA + […]