Monthly Archives: August 2012

Add Text Annotations to ggplot2 Faceted Plot

August 31, 2012
By
Add Text Annotations to ggplot2 Faceted Plot

In my experience with R learners there are two basic types. The “show me the code and what it does and let me play” type and the “please give me step by step directions” type. I’ve broken the following tutorial … Continue reading →

Read more »

On School Boards and Policy Shocks

August 31, 2012
By
On School Boards and Policy Shocks

The dissertation process has many steps. The prospectus or proposal is one of the last. Awhile ago I was lucky enough to have my dissertation proposal defense and pass!  My project is seeking to understand the linkage between political activity at...

Read more »

Compiling Source Packages on R 2.15.x / Mac OS 10.5.x

August 31, 2012
By

For some reason R is not happy with its 64-bit cousin when installing source packages: * installing *source* package ‘XMLSchema’ ... ** R ** inst ** preparing package for lazy loading ** help *** installing help indices ** building package indices ** installing vignettes ** testing if installed package can be loaded *** arch - i386 *** arch - x86_64 /Library/Frameworks/R.framework/Resources/bin/R: line 259: /Library/Frameworks/R.framework/Resources/bin/exec/x86_64/R: Bad CPU type in executable /Library/Frameworks/R.framework/Resources/bin/R: line 259:...

Read more »

RStan: Fast, multilevel Bayesian modeling in R

August 31, 2012
By

For the last decade or so, the go-to software for Bayesian statisticians has been BUGS (and later the open-source incarnation, OpenBugs, or JAGS). BUGS is used for multi-level modeling: using a specialized notation, you can define random variables of various distributions, set Bayesian priors for their parameters, and create the network of relationships that describe how the random variables...

Read more »

Border bias and weighted kernels

August 31, 2012
By
Border bias and weighted kernels

With Ewen (aka @3wen), not only we have been playing on Twitter this month, we have also been working on kernel estimation for densities of spatial processes. Actually, it is only a part of what he was working on, but that part on kernel estimation...

Read more »

Compiling rgdal on Mac OS 10.5

August 31, 2012
By

Why do I always forget how to do this? R CMD INSTALL rgdal --configure-args="--with-gdal-config=/Library/Frameworks/GDAL.framework/Versions/Current/unix/bin/gdal-config --with-proj-include=/Library/Frameworks/PROJ.framework/Versions/4/Headers/ --with-proj-lib=/Library/Frameworks/PROJ.framework/Versions/Current/unix/lib/" You will need to adjust the paths based on your version of the GDAL and Proj4 frameworks. read more

Read more »

Russell 2000 Softail Fat Boy

August 31, 2012
By
Russell 2000 Softail Fat Boy

If the Russell 2000 were a motorcycle, maybe it should be a Harley-Davidson Softail Fat Boy.  I have explored the exception case of the Russell 2000 in quite a few posts More Exploration of Crazy RUT Where are the Fat Tails? Crazy RUT but I st...

Read more »

Border bias and weighted kernels

August 31, 2012
By
Border bias and weighted kernels

With Ewen (aka @3wen), not only we have been playing on Twitter this month, we have also been working on kernel estimation for densities of spatial processes. Actually, it is only a part of what he was working on, but that part on kernel estimation has been the opportunity to write a short paper, that can now be downloaded on hal. The problem...

Read more »

Another bunch of R (and JAGS) scripts

August 31, 2012
By
Another bunch of R (and JAGS) scripts

Probably sooner than I expected, I have managed to also upload the codes for the examples in Chapter 5 of the book, which deals with doing Bayesian health economic evaluations. Basically, there are 3 examples, which sort of represent the main clas...

Read more »

PCA or Polluting your Clever Analysis

August 31, 2012
By
PCA or Polluting your Clever Analysis

When I learned about principal component analysis (PCA), I thought it would be really useful in big data analysis, but that's not true if you want to do prediction. I tried PCA in my first competition at kaggle, but it delivered bad results. This post illustrates how PCA can pollute good predictors.When I started examining this problem,...

Read more »