1832 search results for "ggplot2"

Randomization thoughts

April 27, 2012
By
Randomization thoughts

Le Grand Casino of Monte CarloOn Monday I’m going to be leading a little stats workshop on randomization tests and null models. In preparation for this I wrote up code for null model examples I wanted to write a post that introduced the basics of these models (Null models, bootstrapping,...

Read more »

phyloseq: Reproducible interactive analysis of microbiome census data using R

April 26, 2012
By
phyloseq: Reproducible interactive analysis of microbiome census data using R

Collaborative development of phyloseq on GitHub. Official stable release of phyloseq on Bioconductor. Advances in DNA sequencing technology have dramatically improved the scope and scale of culture-independent investigations into microbial communities. There are effective software tools available to process raw DNA … Continue reading →

Read more »

Live Longer – Choose Your Country Wisely (if you can)

April 25, 2012
By
Live Longer – Choose Your Country Wisely (if you can)

Full democracy countries are the ones in which to live. This week's story could start and end with the above graph with almost no further explanation. But that wouldn't do it justice. So, like so many of the past articles on "Graph o...

Read more »

Varying Window Length for Linear Models on Stocks

April 24, 2012
By
Varying Window Length for Linear Models on Stocks

In a previous post, we discussed ideas generated by a Timely Portfolio post about Linear Models on Stock. I wanted to see if there was a relationship between the window length of the running mean of the linear regression slope estimate and the running mean of the correlation between fitted and observed values. The parameters

Read more »

How to remember point shape codes in R

April 24, 2012
By
How to remember point shape codes in R

I suspect I am not unique in not being able to remember how to control the point shapes in R. Part of this is a documentation problem: no package ever seems to write the shapes down. All packages just use the “usual set” that derives from S-Plus and was carried through base-graphics, to grid, lattice Related posts:

Read more »

Short R script to plot effect sizes (Cohen’s d) and shade overlapping area

April 23, 2012
By
Short R script to plot effect sizes (Cohen’s d) and shade overlapping area

In this short post I take a look at how to use R and ggplot2 to visualize effect sizes (Cohen’s d) and how to shade the overlapping area of two distributions.

Read more »

Probit/Logit Marginal Effects in R

April 23, 2012
By
Probit/Logit Marginal Effects in R

The common approach to estimating a binary dependent variable regression model is to use either the logit or probit model. Both are forms of generalized linear models (GLMs), which can be seen as modified linear regressions that allow the dependent variable to originate from non-normal distributions. The coefficients in a linear regression model are marginal

Read more »

Visualising the Path of a Genetic Algorithm

April 23, 2012
By
Visualising the Path of a Genetic Algorithm

We quite regularly use genetic algorithms to optimise over the ad-hoc functions we develop when trying to solve problems in applied mathematics. However it’s a bit disconcerting to have your algorithm roam through a high dimensional solution space while not being able to picture what it’s doing or how close one solution is to another. … Continue reading...

Read more »

118 years of US State Weather Data

April 22, 2012
By
118 years of US State Weather Data

A recent post on the Junkcharts blog looked at US weather dataand the importance of explaining scales (which in this case went up to 118). Ultimately, it turns out that 118 is the rank of the data compared to the previous 117 years of data (in ascending order, so that 118 is the highest). At … Continue reading...

Read more »

Generating all subsets of a set

April 20, 2012
By
Generating all subsets of a set

Recently I have calculated Banzhaf power index. I required generation of all subsets of a given set. The code given there was a bit complex and I have decided to write a simple function calculating it. As an example of its application I reproduce Figur...

Read more »