Articles by Markus Gesmann

Creating a matrix from a long data.frame

October 1, 2013 | Markus Gesmann

There can never be too many examples for transforming data with R. So, here is another example of reshaping a data.frame into a matrix.Here I have a data frame that shows incremental claim payments over time for different loss occurrence (origin) years... [Read more...]

Changing the width of bars and columns in googleVis

September 24, 2013 | Markus Gesmann

Changing the plotting width in bar-, column- and combo-charts of googleVis works identical and is defined by the bar.groupWidth argument. The dot in the argument means that it has to be split in R into bar="{groupWidth:'10%'}". Example
library(googleVis)<br>cc                       xvar="Country", yvar="Population",<br>                      options=list(seriesType="bars", legend="top",<br>                                   bar="{groupWidth:'10%'}",<br>                                   width=500, height=450),<br>                      chartid="thincolumns")<br>plot(cc)
Your browser doesn't support iframes.Session Info
R version 3.0.1 (2013-05-16)<br>Platform: x86_64-apple-darwin10.8.0 (64-bit)<br><br>locale:<br>[1] en_GB.UTF-8/en_GB.UTF-8/en_GB.UTF-8/C/en_GB.UTF-8/en_GB.UTF-8<br><br>attached base packages:<br>[1] stats     graphics  grDevices utils     datasets  methods   base     <br><br>other attached packages:<br>[1] googleVis_0.4.5<br><br>loaded via a namespace (and not attached):<br>[1] RJSONIO_1.0-3 tools_3.0.1
[Read more...]

Using planel.groups in lattice

September 17, 2013 | Markus Gesmann

Last Tuesday I attended the LondonR user group meeting, where Rich and Andy from Mango argued about the better package for multivariate graphics with R: lattice vs. ggplot2. As part of their talk they had a little competition in visualising London Unde...
[Read more...]

ave and the [ function in R

September 10, 2013 | Markus Gesmann

The ave function in R is one of those little helper function I feel I should be using more. Investigating its source code showed me another twist about R and the "[" function. But first let's look at ave.The top of ave's help page reads:Group Averages Over Level Combinations ... [Read more...]

Doughnut chart in R with googleVis

September 3, 2013 | Markus Gesmann

The guys at Google continue to update and enhance the Chart Tools API. One new recent feature is a pie chart with a hole, or as some call them: donut charts.Thankfully the new functionality is being achieved through new options for the existing pie cha... [Read more...]

Setting axes limits with googleVis

August 6, 2013 | Markus Gesmann

I posted about the various googleVis axis options for base charts, such as line, bar and area charts earlier, but I somehow forgot to mention how to set the axes limits.Unfortunately, there are no arguments such as ylim and xlim. Instead, the Google Ch... [Read more...]

R in Insurance: Presentations are online

July 31, 2013 | Markus Gesmann

The programme and the presentation files of the first R in Insurance conference have been published on GitHub. Front slides of the conference presentations Additionally to the slides many presenters have made their R code available as well: Alexander McNeil shared the examples of the CreditRisk+ model he presented. Lola ... [Read more...]

Review: Kölner R Meeting 19 July 2013

July 23, 2013 | Markus Gesmann

Despite the hot weather and the beginning of the school holiday season in North Rhine Westphalia the Cologne R user group met yet again for two fascinating talks and beer and schnitzel afterwards.Analysing Twitter data to evaluate the US Dollar / Euro exchange rates Dietmar Janetzko presented ideas to forecast ... [Read more...]

Quick review: R in Insurance Conference

July 16, 2013 | Markus Gesmann

Yesterday the first R in Insurance conference took place at Cass Business School in London. I think the event went really well, but as a member of the organising committee my view is probably skewed. Still, we had a variety of talks, a full house, a gr... [Read more...]

googleVis tutorial at useR!2013

July 9, 2013 | Markus Gesmann

Today Diego and I will give our googleVis tutorial at useR!2013 in Albacete, Spain.googleVis Tutorial at useR! 2013We will cover:Introduction and motivationGoogle Chart ToolsR package googleVisConcepts of googleVisCase studiesgoogleVis on shiny [Read more...]

There is definitely R in July

July 1, 2013 | Markus Gesmann

The useR!2013 conference in Albacete, Spain, will commence next Wednesday, 10 July, and on the day before Diego and I will give a googleVis tutorial. The following Monday, 15 July, the first R in Insurance event will take place at Cass Business School ... [Read more...]

googleVis 0.4.3 released with improved Geocharts

June 18, 2013 | Markus Gesmann

The Google Charts Tools provide two kinds of heat map charts for geographical data, the Flash based Geomap and the HTML5/SVG based Geochart. I prefer the Geochart as it doesn't require Flash, but so far there have been two shortcomings with it: I couldn't add additional tooltip information and ... [Read more...]

R package development

June 11, 2013 | Markus Gesmann

Building R packages is not particular hard, but it can be a bit of a daunting endeavour at the beginning, particularly if you are more of a statistician than a computer scientist or programmer. Some concepts may appear foreign or like red tape, yet man... [Read more...]

Interactive slides with googleVis on shiny

June 4, 2013 | Markus Gesmann

Following on from last week's post, here are my slides on using googleVis on shiny from the Advanced R workshop at Lancaster University, 21 May 2013. googleVis on shiny Again, I wrote my slides in RMarkdown and I used slidify to create the HTML5 presentation. Unfortunately you may have to reload the ... [Read more...]

Claims Inflation – a known unknown

May 14, 2013 | Markus Gesmann

Over the last year I worked with two colleagues of mine on the subject of inflation and claims inflation in particular. I didn't expect it to be such a challenging topic, but we ended up with more questions than answers. The key question and biggest ch... [Read more...]

How to change the alpha value of colours in R

April 29, 2013 | Markus Gesmann

Often I like to reduce the alpha value (level of transparency) of colours to identify patterns of over-plotting when displaying lots of data points with R. So, here is a tiny function that allows me to add an alpha value to a given vector of colours, e.g. a RColorBrewer ... [Read more...]
1 5 6 7 8 9 11

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)