Claims reserving and IBNR with R

June 6, 2012
By
Claims reserving and IBNR with R

Following previous posts on life contingencies and longevity and mortality models, I upload additional material for the short course at the 6th R/Rmetrics Meielisalp Workshop & Summer School on Computational Finance and Financial Engineeri...

Read more »

Let’s Party!

June 6, 2012
By
Let’s Party!

Exploring whether regression coefficients differ between groups is an important part of applied econometric research, and particularly for research with a policy based objective. For example, a government in a developing country may decide to introduce free school lunches in an effort to improve childhood health. However, if this treatment is known to only improve

Read more »

Project Euler — problem 7

June 6, 2012
By

Prime is the core of number theory. Here is an introduction of prime number on Wikipedia. I could only understand roughly half of it. Now, let’s look at the seventh problem of Project Euler, which is another about prime number.  By listing the first six prime numbers: 2, 3, … Continue reading →

Read more »

2 min HOWTO in R

June 6, 2012
By

Lots of short videos on how to do several things in R.

Read more »

Facts About R Packages (2)

June 6, 2012
By

R Packages All Well maintained? There are so many R packages, can they all be trusted? or are they well maintained? To answer this question, we just need to take a look of their archive histories. If a package has many versions, we can take that as the authors spent a lot of time to make their packages perfect, these...

Read more »

R-NOLD 2012-06-06 03:18:00

June 6, 2012
By
R-NOLD 2012-06-06 03:18:00

While traveling across the Visayas, I encountered barangay (villages) with the name same as my last name. Using R and map data from gadm.org I search and mapped other villages in the country named “Salvacion”.

Read more »

Facts About R Packages (1)

June 6, 2012
By

R Packages growth Curve Why R is so popular? There are a lot of reasons, such as: easy to learn and convenient to use, active community, open source, etc. Another important reason is the numerous contributed packages. Up to yesterday, there are 3854 R packages on CRAN. The following figure shows the growth curve of R package:

Managing the deluge of DNA data

June 5, 2012
By
Managing the deluge of DNA data

The explosion in DNA sequencing capacity has shifted the experimental bottleneck from sequencing to analyzing and interpreting sequences. The bioconductor package cummeRbund uses ggplot as part of its tool set for organizing, exploring and visualizing ...

Read more »

Constants and ARIMA models in R

June 5, 2012
By
Constants and ARIMA models in R

This post is from my new book Forecasting: principles and practice, available freely online at OTexts.com/fpp/. A non-seasonal ARIMA model can be written as (1)   or equivalently as (2)   where is the backshift operator, and is the mean of . R uses the parametrization of equation (2). Thus, the inclusion of a constant in a non-stationary ARIMA...

Read more »

Quasi-Random Number Generation in R

Random number generation is a core topic in numerical computer science. There are many efficient algorithms for generating random (strictly speaking, pseudo-random) variates from different probability distributions. The figure below shows a sampling of 1000 two-dimensional random variates from the … Continue reading →

Read more »

F-test to find UECLs

June 5, 2012
By
F-test to find UECLs

I have fixed the link to the video "Removing Y outliers from the validation set" and it´s time to see what could be the next step to the function. As we know the RMSEP is the sum of the explained (BIAS) and unexplained error (SEP). We get also the SEP...

Read more »

Example 9.34: Bland-Altman type plot

June 5, 2012
By
Example 9.34: Bland-Altman type plot

The Bland-Altman plot is a visual aid for assessing differences between two ways of measuring something. For example, one might compare two scales this way, or two devices for measuring particulate matter. The plot simply displays the difference between the measures against their average. Rather than a statistical test, it is intended...

Read more »

NBA Playoff Predictions Update 3 (4-2)

June 5, 2012
By
NBA Playoff Predictions Update 3 (4-2)

This is my third update to my original post on predicting the NBA playoffs with an algorithm. Here are updates 1 and 2. The algorithm correctly predicted a Boston win, but missed on the Spurs/Thunder game, so it is currently 4-2. Haven't had any time...

Read more »

Digitize linear and (semi-)log scale graphs with multiple point sets

June 5, 2012
By
Digitize linear and (semi-)log scale graphs with multiple point sets

Working on a paper, I ran into the problem of needing data from a graph that was not mine, and for which no underlying table was published. With today's software packages, it is however not very difficult to digitize a figure yourself. I remembered rea...

Read more »

Announcing Revolution R Enterprise 6.0

June 5, 2012
By

Revolution Analytics is proud to announce the latest update to our enhanced, production-grade distribution of R, Revolution R Enterprise. This update expands the range of supported computation platforms, adds new Big Data predictive models, and updates to the latest stable release of open source R (2.14.2), which improves performance of the R interpreter by about 30%. This release expands...

Read more »

NBA Playoff Predictions Update 3 (4-2)

June 5, 2012
By
NBA Playoff Predictions Update 3 (4-2)

This is my third update to my original post on predicting the NBA playoffs with an algorithm. Here are updates 1 and 2. The algorithm correctly predicted a Boston win, but missed on the Spurs/Thunder game, so it is currently 4-2. Haven't had any time to update yet, so I will only be able to give you predictions for...

Read more »

Book Review: Parallel R

June 5, 2012
By
Book Review: Parallel R

You have a problem: R is single-threaded, but your code would be faster if it could simultaneously run on more than one core.  You have access to a cluster and/or your computer has multiple cores.  Parallel R, by Q. Ethan McCallum and Stephen...

Read more »

intersect for multiple vectors in R

June 5, 2012
By

Say you havea <- c(1,3,5,7,9)b <- c(3,6,8,9,10)c <- c(2,3,4,5,7,9)A straightforward way to do the job is:intersect(intersect(a,b),c)More cleverly, and more conveniently if you have a lot of arguments:Reduce(intersect, list(a,b,c))The Reduce fu...

Read more »

NBA Playoff Predictions Update 3 (4-2)

June 5, 2012
By
NBA Playoff Predictions Update 3 (4-2)

This is my third update to my original post on predicting the NBA playoffs with an algorithm. Here are updates 1 and 2. The algorithm correctly predicted a Boston win, but missed on the Spurs/Thunder game, so it is currently 4-2. Haven't had any time ...

Read more »

UK house prices visualised with googleVis-0.2.16

June 5, 2012
By
UK house prices visualised with googleVis-0.2.16

A new version of googleVis has been released on CRAN and the project site. Version 0.2.16 adds the functionality to plot quarterly and monthly data as a motion chart. To illustrate the new feature I looked for a quarterly data set and stumbled across t...

Read more »

Volatility Quantiles

June 4, 2012
By
Volatility Quantiles

Today I want to examine the performance of stocks in the S&P 500 grouped into Quantiles based on one year historical Volatility. The idea is very simple: each week we will form Volatility Quantiles portfolios by grouping stocks in the S&P 500 into Quantiles using one year historical Volatility. Next we will backtest each portfolio

Read more »

Applications of R in Government

June 4, 2012
By

Following the announcement of the US Government Big Data Initiative, I was asked to write a small article about applications of R in government. The article has just appeared in Government Security News (and I believe will appear in their daily newsletter tomorrow). In the article, I highlighted several R applications that been highlighted here in the blog: In...

Read more »

Download and parse EDHEC hedge fund indexes

June 4, 2012
By
Download and parse EDHEC hedge fund indexes

In our pre-conference workshop, Brian Peterson and I worked with the EDHEC hedge fund indexes as a way to demonstrate how to use PortfolioAnalytics within the context of long-term allocation problems. Although they are not investible, these indexes are probably more representative than most given that they are, in fact, meta-indexes. Other indexes might be

Read more »

Longevity and mortality dynamics with R

June 4, 2012
By
Longevity and mortality dynamics with R

Following the previous post on life contingencies and actuarial models in life insurance, I upload additional material for the short course at the 6th R/Rmetrics Meielisalp Workshop & Summer School on Computational Finance and Financial Engineering organized by ETH Zürich, https://www.rmetrics.org/. The second part of the talk (on Actuarial models with R) will be dedicated to longevity and mortality. A complete...

Read more »

Announcing RPubs: A New Web Publishing Service for R

June 4, 2012
By
Announcing RPubs: A New Web Publishing Service for R

Today we’re very excited to announce RPubs, a free service that makes it easy to publish documents to the web from R. RPubs is a quick and easy way to disseminate data analysis and R code and do ad-hoc collaboration with peers. RPubs documents are based on R Markdown, a new feature of knitr 0.5 and RStudio 0.96. To publish

Read more »

Longevity and mortality dynamics with R

June 4, 2012
By
Longevity and mortality dynamics with R

Following the previous post on life contingencies and actuarial models in life insurance, I upload additional material for the short course at the 6th R/Rmetrics Meielisalp Workshop & Summer School on Computational Finance and Financial En...

Read more »

Extracting an image chunk from a collection of Large MrSid Images

June 4, 2012
By

Recently needed to extract a small "chunk" from a collection of adjacent MrSid mosaics, each about 4Gb in size. Once again, GDAL came to the rescue, and saved much time and agony wile working with very large, compressed, and proprietary-format files. T...

Read more »

Generate Quasi-Poisson Distribution Variable

June 4, 2012
By

Most of regression methods assume that the response variables follow some exponential distribution families, e.g. Guassian, Poisson, Gamma, etc. However, this assumption was frequently violated in real world data by, for example, zero-inflated overdispersion problem. A number of methods were developed to deal with such problem, and among them, Quasi-Poisson and Negative Binomial are the most popular methods perhaps due...

Read more »

Announcing The R markdown Package

June 4, 2012
By

Many of you have heard about RStudio’s latest release and it’s new R Markdown feature. Today, I’d like to announce the markdown package for R, a tool for converting Markdown documents to HTML, created in collaboration with RStudio. It...

Read more »