Using paste( ) to read and write multiple files in R

August 19, 2012
By

This post is a quick tip on how to use the paste( ) function to read and write multiple files. First, let’s create some data. The next step is not necessary, but makes the subsequent code more readable. The following example is silly because you would rarely want to split your data as

Read more »

Horizon plots with ggplot2, sort-of

August 19, 2012
By
Horizon plots with ggplot2, sort-of

The Timely Portfolio blog via R-bloggers has recently published some interesting entries about the value of horizon plots for visual comparison of a number of time series. Very nice it looks too. You can read more about them here. The trick to understanding them is to imagine that each row was orginally a line chart … Continue reading...

Read more »

R for Ecologists: Putting Together a Piecewise Regression

August 19, 2012
By
R for Ecologists: Putting Together a Piecewise Regression

Piecewise regression comes about when you have ‘breakpoints’, where there are clearly two different linear relationships in the data with a sudden, sharp change in directionality. This crops up occasionally in ecology when dealing with, for example, species richness of understory plants … Continue reading →

Read more »

London 2012 Olympics — Medals per hundred players

August 19, 2012
By
London 2012 Olympics — Medals per hundred players

It’s the weekend. I just woke up from a nap. Got my mind freshed. I’d like to continue with my digging into the Olympics medal results. Today, I cited the number of participants from each country (see wikipedia). I want to see how … Continue reading →

Read more »

Linear regression in OpenBUGS

August 18, 2012
By

I always wondered why is it so difficult to find an OpenBUGS example of simple linear regression on the Web. Curiously, such example is even missing in the OpenBUGS help. The only nice example so far is in the book … Continue reading →

Read more »

Parallelization: Speed up Functions in a Package

August 18, 2012
By
Parallelization: Speed up Functions in a Package

Well I bought a new computer a month back (i7 8GB memory). Finally more than one core and a chance to try parallelization. I saw this blog post a while back and was intrigued and was further intriqued when I … Continue reading →

Read more »

Querying a database from within R

August 18, 2012
By
Querying a database from within R

For a while now I have been contemplating pulling data from our postgreSQL db directly from R, but just never actually pulled the trigger until today.  What I found was that it was a lot easier than I ever could have imagined.  My laptop was already on the VPN, so I decided to try it

Read more »

read raster data in parallel

August 18, 2012
By
read raster data in parallel

Use library(parallel) to read raster data in parallel fashion Use library(parallel) to read raster data in parallel fashion Recently, I have been doing some analysis for a project I am involved in. In particular, I was...

Read more »

An example of OOP in GNU R using S4 Classes

August 18, 2012
By
An example of OOP in GNU R using S4 Classes

Recently I have discussed with my friend from WLOG Solutions an implementation of banking cash management engine in GNU R. The code made a nice use of S4 classes so I thought it would be worth showing as an example.The problemEvery commercial bank need...

Read more »

Experience with Oracle R Enterprise in the Oracle micro-processor tools environment

August 17, 2012
By
Experience with Oracle R Enterprise in the Oracle micro-processor tools environment

Normal 0 false false false EN-US X-NONE X-NONE ...

Read more »

GARCH Panel in plot.xts

August 17, 2012
By
GARCH Panel in plot.xts

I’m clearly out of my realm of competence with most of the rugarch functions, but I thought it might be nice to provide an example combining plot.xts and uGARCHroll. R code from GIST:

Read more »

Ryan Rosario on Parallel programming in R

August 17, 2012
By

Earlier this year data scientist Ryan Rosario gave a talk on parellel computing with R to the Los Angeles R User Group, and he recently made the slides from the talk available online. They're a great resource for anyone looking to make use of multi-processor systems a Hadoop based architechure to speed computations with big data. Ryan's talk was...

Read more »

Using R from Inside Statistica

August 17, 2012
By
Using R from Inside Statistica

I’ve been spending a lot of time in the last month or so doing projects at work not statistics related, hence the lack of posts!  In the interim, I had to do some serious research on handling datasets bigger than … Continue reading →

Read more »

London 2012 Olympics — Lead, tin and zinc

August 17, 2012
By
London 2012 Olympics — Lead, tin and zinc

Folks at WSJ were funny. They gave another medal list of London 2012 Olympic Games, not for the first place but for the last place. They replaced Gold, Silver and Bronze with  Lead, Tin and Zinc. No matter who came up to this idea, it’s … Continue reading →

Read more »

Predictive analytics: Some ways to waste time

August 17, 2012
By
Predictive analytics: Some ways to waste time

I am starting to take part at different competitions at kaggle and crowdanalytics. The goal of most competitions is to predict a certain outcome given some covariables.  It is a lot of fun trying out different methods like random forests, boosted ...

Read more »

Horizon Plots with plot.xts

August 17, 2012
By
Horizon Plots with plot.xts

Anyone who has read 48 Industries (Dendrogram Ordered) Over 50 Years 48 Industries Since 1963 “Trend is Not Your Friend” Applied to 48 Industries Horizon Plots in Base Graphics More on Horizon Charts Application of Horizon Plots Horizon Plo...

Read more »

An update on visualizing Bayesian updating

August 17, 2012
By
An update on visualizing Bayesian updating

A while ago I wrote this post with some R code to visualize the updating of a beta distribution as the outcome of Bernoulli trials are observed. The code provided a single plot of this process, with all the curves overlayed on top of one another. Then John Myles White (co-author of Machine Learning for

Read more »

Follow-up to Counting CRAN Package Depends, Imports and LinkingTo

August 16, 2012
By
Follow-up to Counting CRAN Package Depends, Imports and LinkingTo

A few days ago, I blogged about visualizing CRAN dependency ranks which turned out to be a somewhat popular post. David Smith followed-up at the REvo blog suggesting to exclude packages already shipping with R (which is indicated by their 'Recommended' priority). Good idea! So here is an updated version, where we limit the display to the top twenty packages counted by reverse 'Depends:',...

Read more »

The Setup (Part 1)

August 16, 2012
By
The Setup (Part 1)

One of the more challenging things about beginning graduate school was learning what tools and software I needed in order to work efficiently. Unlike college where software requirements were laid out in front of me and everyone seemed to use … Continue reading →

Read more »

How Williams Sonoma uses R to target customers online

August 16, 2012
By
How Williams Sonoma uses R to target customers online

If you live in the US, you've probably visited a Williams Sonoma store for gourmet food or quality cookware for the kitchen. And if you've shopped at Pottery Barn or West Elm stores for furniture, those chains are part of the Williams Sonoma stable as well. All three brands have major online stores, all supported by a sophisticated marketing...

Read more »

plot.xts is wonderful

August 16, 2012
By
plot.xts is wonderful

As mentioned in FOSS Trading post A New plot.xts yesterday “The Google Summer of Code (2012) project to extend xts has produced a very promising new plot.xts function. Michael Weylandt, the project's student, wrote R-SIG-Finance to request impressio...

Read more »

Video on S3 Classes in R by Dr Andrew Robinson

August 16, 2012
By
Video on S3 Classes in R by Dr Andrew Robinson

This post shares the video from the talk presented on 15th August 2012 by Dr Andrew Robinson on S3 Classes at Melbourne R Users. S3 classes are baked in to R; their influence permeates the language and how we interact … Continue reading →

Read more »

INLA: Bayes goes to Norway

August 15, 2012
By
INLA: Bayes goes to Norway

INLA is not the Norwegian answer to ABBA; that would probably be a-ha. INLA is the answer to ‘Why do I have enough time to cook a three-course meal while running MCMC analyses?”. Integrated Nested Laplace Approximations (INLA) is based … Continue reading →

Read more »

Conference Presentations

August 15, 2012
By
Conference Presentations

I recently gave a talk at the Ecological Society of America (ESA) annual meeting in Portland, OR and a poster presentation at the World Congress of Herpetology meeting in Vancouver, BC, Canada. Both presentations were comparing generalized linear mixed models … Continue reading →

Read more »

Twitter coverage of the ISMB 2012 meeting: some statistics

August 15, 2012
By
Twitter coverage of the ISMB 2012 meeting: some statistics

OK, let’s do this: some statistics and visualization of the tweets for ISMB 2012. First, thanks to Stephen Turner who got things started in this post at his excellent blog, Getting Genetics Done. Subscribe to his feed if you don’t already do so. I’ve created a Github repository for this project (and future Twitter-related work).

Read more »

(Manually) making letters with geom_path() – fun example

August 15, 2012
By
(Manually) making letters with geom_path() – fun example

Disclaimer, maybe the title should be ‘lame example’. Nothing overly exciting here. Just posting cause it took a little faffing about and someone else might like the idea. At my work (research institute) we (the social club committee) were organising … Continue reading →

Read more »

New Revolution Analytics office in Singapore

August 15, 2012
By

We're excited to announce the latest outpost of the Revolution Analytics team, with the opening of a new office in Singapore! This office will serve as the local HQ for Revolution Analytics serving our customers in the Asia-Pacific region. It was opened with the support of the support of the Infocomm Development Authority of Singapore, which is responsible for...

Read more »

Why trust some supposed laws of statistical sampling and…

August 15, 2012
By

Why trust some supposed laws of statistical sampling and convergence when you can just test them yourself? If you have a computer with R installed (also recommended: Rstudio) then you can stop dithering about whether these n=1000 studies cited in the n...

Read more »

What does a generalized linear model do?

August 15, 2012
By
What does a generalized linear model do?

What does a generalized linear model do? R supplies a modeling function called glm() that fits generalized linear models (abbreviated as GLMs). A natural question is what does it do and what problem is it solving for you? We work some examples and place generalized linear models in context with other techniques.For predicting a categorical Related posts:

Read more »