Articles by Scott Chamberlain

Treebase trees from R

May 3, 2011 | Scott Chamberlain

Treebase is a great resource for phylogenetic trees, and has a nice interface for searching for certain types of trees. However, if you want to simply download a lot of trees for analyses (like that in Davies et al.), then you want to be able to access...
[Read more...]

Processing nested lists

April 28, 2011 | Scott Chamberlain

So perhaps you have all figured this out already, but I was excited to figure out how to finally neatly get all the data frames, lists, vectors, etc. out of a nested list. It is as easy as nesting calls to the apply family of functions, in the case bel...
[Read more...]

Phylometa from R – UDPATE

April 1, 2011 | Scott Chamberlain

A while back I posted some messy code to run Phylometa from R, especially useful for processing the output data from Phylometa which is not easily done. The code is still quite messy, but it should work now. I have run the code with tens of different d...
[Read more...]

basic ggplot2 network graphs – ver2

March 23, 2011 | Scott Chamberlain

I posted last week a simple function to plot networks using ggplot2 package. Here is version 2. I still need to work on figuring out efficient vertex placement.Changes in version 2:-You have one of three options: use an igraph object, a matrix, or a da...
[Read more...]

basic ggplot2 network graphs

March 17, 2011 | Scott Chamberlain

I have been looking around on the web and have not found anything yet related to using ggplot2 for making graphs/networks. I put together a few functions to make very simple graphs. The bipartite function especially is not ideal, as of course we only w...
[Read more...]

Phenotypic selection analysis in R

February 24, 2011 | Scott Chamberlain

I have up to recently always done my phenotypic selection analyses in SAS. I finally got some code I think works to do everything SAS would do. Feedback much appreciated!########################Selection analyses#############################install.pac...
[Read more...]

Good riddance to Excel pivot tables

January 30, 2011 | Scott Chamberlain

Excel pivot tables have been how I have reorganized data...up until now. These are just a couple of examples why R is superior to Excel for reorganizing data:################ Good riddance to pivot tables ############library(reshape2)library(plyr)&nbsp...
[Read more...]

R and Google Visualization API: Fish harvests

January 17, 2011 | Scott Chamberlain

I recently gathered fish harvest data from the U.S. National Oceanic and Atmospheric Administarion (NOAA), which I downloaded from Infochimps. The data is fish harvest by weight and value, by species for 21 years, from 1985 to 2005. Here is a link to a google document of the data I used below: ...
[Read more...]

Bipartite networks and R

January 14, 2011 | Scott Chamberlain

Earlier, I posted about generating networks from abundance distributions that you specify. If this post was interesting, check out Jeff Kilpatrick's website, where he provides code he produced in R and Octave to compare real bipartite networks to ones ...
[Read more...]

R and Google Visualization API

January 8, 2011 | Scott Chamberlain

R interfaces with the powerful Google Visualization API with the package googleVis (see here). It's relatively easy to convert your graphics in R to interactive graphics to post on a web browser. And the graphics are quite nice, as seen below in a simple graph of some of my data ...
[Read more...]
1 2 3 4

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)