R Language

A slice of S&P 500 kurtosis history

February 13, 2012 | Pat

How fat tailed are returns, and how does it change over time? Previously The sister post of this one is “A slice of S&P 500 skewness history”. Orientation The word “kurtosis” is a bit weird.  The original idea was of peakedness — how peaked is the distribution at the center.  That’... [Read more...]

Vectorized R vs Rcpp

February 1, 2012 | Dzidorius Martinaitis

In my previous post, I tried to show, that Rcpp is 1000 faster than pure R and that generated the fuss in the comments. Being lazy, I didn’t vectorize R code and at the end I was comparing apples vs oranges. To fix that problem, I built a new script, ... [Read more...]

The power of Rcpp

January 30, 2012 | Dzidorius Martinaitis

While ago I built two R scripts to track OMX Baltic Benchmark Fund against the index. One script returns the deviation of  fund from the index and it works fast enough. The second calculates the value of the fund every minute and it used to take for while. For example, ... [Read more...]

The distribution of financial returns made simple

January 23, 2012 | Pat

Why returns have a stable distribution As “A tale of two returns” points out, the log return of a long period of time is the sum of the log returns of the shorter periods within the long period. The log return over a year is the sum of the daily ... [Read more...]

How to search the R-sig-finance archives

January 19, 2012 | Pat

A not unusual part of a response on the R-sig-finance mailing list is: “Search the list archives.” In principle that makes sense.  In practice it might not be clear what to do.  Now it should be. The list The R-sig-finance mailing list deals with the intersection of questions about the ...
[Read more...]

A slice of S&P 500 skewness history

January 16, 2012 | Pat

How symmetric are the returns of the S&P 500? How does the skewness change over time? Previously We looked at the predictability of kurtosis and skewness in S&P constituents.  We didn’t see any predictability of skewness among the constituents.  Here we look at skewness from a different angle. ... [Read more...]

CRdata.org to shut down?

January 16, 2012 | PR

If you’re one of the R-bloggers or useRs, most probably you had heard about Crdata.org. In the early day, they are two very R related cloud computing services, one is CloudNumbers, another is CrData.org. Recently, we (may) received an email by Hamid ... [Read more...]

Scraping table from any web page with R or CloudStat

January 15, 2012 | PR

Scraping table from any web page with R or CloudStat: You need to use the data from internet, but don’t type, you can just extract or scrape them if you know the web URL. Thanks to XML package from R. It provides amazing readHTMLtable() function. For... [Read more...]

Scraping table from html web with CloudStat

January 12, 2012 | CloudStat

You need to use the data from internet, but don’t type, you can just extract or scrape them if you know the web URL. Thanks to XML package from R. It provides amazing readHTMLtable() function. For a study case, I want to scrape data: US Airline Custo... [Read more...]

Physical books of “The R Inferno” and “S Poetry”

January 12, 2012 | Pat

Hardcopy versions of both The R Inferno and S Poetry are now available for sale. Physical economy Buy The R Inferno (the version dated 2011 April 30)   Buy S Poetry Discount The publisher, Lulu, has a coupon for a 25% discount off purchases (up to a maximum of $50) that is good until the … ... [Read more...]

Sensitivity of risk parity to variance differences

January 9, 2012 | Pat

Equal risk contribution of assets determines the asset weights given the variance matrix.  How sensitive are those weights to the variance estimate? Previously The post “Risk parity” gave an overview of the idea. In particular it distinguished the cases: the assets have equal risk contribution groups of assets have equal ... [Read more...]

The top 7 portfolio optimization problems

January 5, 2012 | Pat

Stumbling blocks on the trek from theory to practical optimization in fund management. Problem 1: portfolio optimization is too hard If you are using a spreadsheet, then this is indeed a problem. Spreadsheets are dangerous when given a complex task.  Portfolio optimization qualifies as complex in this context (complex in data ...
[Read more...]

Market predictions for years 2011 and 2012

January 2, 2012 | Pat

A review of market predictions and results for 2011, and a calibration for 2012 predictions (of 19 equity indices plus oil). Previously One year ago the post “Revised market prediction distributions” presented plots showing the variability of various markets assuming no market-moving forces. The follow-up post “Some market predictions enhanced some of those ... [Read more...]
1 2 3 4 5 6 10

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)