2150 search results for "twitter"

Fixing aberrant files using R and the shell: a case study

April 7, 2011
By
Fixing aberrant files using R and the shell: a case study

Once in a while, you embark on what looks like a simple computational procedure only to encounter frustration very early on. “I can’t even read my file into R!” you cry. Step back, take a deep breath and take note of what the software is trying to tell you. Most times, you’ve just missed something

Read more »

Buffon versus Bertrand in R

April 7, 2011
By
Buffon versus Bertrand in R

Following my earlier post on Buffon’s needle and Bertrand’s paradox, above are four outcomes corresponding to four different generations (among many) of the needle locations. The upper right-hand side makes a difference in the number of hits (out of 1000). The R code corresponding to this generation was made in the métro, so do not

Read more »

Alpha shapes with R and lattice

Alpha shapes with R and lattice

What are the alpha shapes?: “The concept of alpha shapes formalizes the intuitive notion of “shape” for spatial point set data, which occurs frequently in the computational sciences. An alpha shape is a concrete geometric object that is uniquely defined for a particular point set. Alpha shapes are generalizations of the convex hull. Given a

Read more »

When Buffon meets Bertrand

April 6, 2011
By
When Buffon meets Bertrand

When Peter Diggle gave his “short history” of spatial statistics this morning (I typed this in the taxi from Charles de Gaulle airport, after waiting one hour for my bag!), he started with a nice slide about Buffon’s needle (and Buffon’s portrait), since Julian Besag was often prone to give this problem as a final

Read more »

How to: Multinomial regression models in R

April 5, 2011
By
How to: Multinomial regression models in R

Apples, oranges, pears or bananas? Bus, train, car, or walk? Many choices are made between more than two options, a situation that can be represented by multinomial choice modelling. Here's a quick tutorial on how to do it in R.

Read more »

Comparison of compression

April 4, 2011
By
Comparison of compression

I recently wrote an email with an attached LZMA archive. It was immediately answered with something like: "What are you doing? I had to boot linux to open the file!" First of all I don't care whether user of proprietary systems are able to read open formats, but this answer made me curious to know about the differences between some compression...

Read more »

Maps of solar radiation

Maps of solar radiation

The Atmospheric Science Data Center (ASDC) at NASA Langley Research Center offers several data sources. For example, it is possible to download a text file with the 22-year (July 1983 – June 2005) monthly and annual average of global horizontal irradiation. nasafile <- 'http://eosweb.larc.nasa.gov/sse/global/text/global_radiation' nasa <- read.table(file=nasafile, skip=13, header=TRUE) With this data, R and the

Read more »

Violin and boxplots with lattice and R

Violin and boxplots with lattice and R

A violin plot is a combination of a boxplot and a kernel density plot. Lattice includes the panel.violin function for this graphical tool. This example draws a violin and a boxplot together. First, let’s download some solar radiation data from the NASA webpage: nasafile <- 'http://eosweb.larc.nasa.gov/sse/global/text/global_radiation' nasa <- read.table(file=nasafile, skip=13, header=TRUE) Now, I plot a

Read more »

Find NHL Players with 30 Goals and 100 PIM using R

April 2, 2011
By
Find NHL Players with 30 Goals and 100 PIM using R

Last week Jack Edwards raised the fact that Milan Lucic was the first Bruin player to join the 30 Goal / 100 Penalty Minute club in a few years.  It got me thinking about the other players who have accomplished … Continue reading →

Read more »

New version of vegan released to CRAN (1.17-9)

April 1, 2011
By
New version of vegan released to CRAN (1.17-9)

Yesterday Jari packaged up the latest release in the current stable branch of the vegan package. Version 1.17-9 of vegan is now on CRAN as a source tarball with binaries for MS Windows and MacOS X to follow soon. New … Continue reading →

Read more »