Posts Tagged ‘ programming ’

R progress indicators

June 18, 2011
By

Complicated calculations usually take a lot of time. So how to know the progress status to estimate how much time the program still needs to finish?

Read more »

sas7bdat database reader update

June 14, 2011
By

An earlier post (1216) introduced a compatibility study (i.e. reverse engineering) of the sas7bdat database file format. The code and documentation for this are here: http://github.com/biostatmatt/sas7bdat. I've recently restructured the code as an R package, and added some functionality. Look for the sas7bdat package on the CRAN. Also, the read.sas7bdat code has been ported to

Read more »

R for the web

May 27, 2011
By

There is a nice R module for apache: rApache. So you can easily publish statistics.

Read more »

Syntax highlighting of R code at WordPress.com

May 20, 2011
By
Syntax highlighting of R code at WordPress.com

If your WordPress blog is hosted at WordPress.com (like this one), you may know that source code in posts is formatted and highlighted using a shortcode, as explained here. Until recently, R was not on the list of supported languages (neither was Perl), but I noticed today that both of them are now supported. This

Read more »

Friday fun projects

May 14, 2011
By
Friday fun projects

What’s a “Friday fun project”? It’s a small computing project, perfect for a Friday afternoon, which serves the dual purpose of (1) keeping your programming/data analysis skills sharp and (2) providing a mental break from the grind of your day job. Ideally, the skills learned on the project are useful and transferable to your work

Read more »

making meat shares more efficient with R and Symphony

May 9, 2011
By
making meat shares more efficient with R and Symphony

In my previous post, I motivated a web application that would allow small-scale sustainable meat producers to sell directly to consumers using a meat share approach, using constrained optimization techniques to maximize utility for everyone involved. In this post, I’ll walk through some R code that I wrote to demonstrate the technique on a small

Read more »

Comments on an R Connections API

May 9, 2011
By

I wrote this post months ago but never hit 'Publish'. But, the subject has changed little since then. So, here's to cleaning out the draft folder... R's connections are the heart of data/code/text input and output. Without connections, R would be crippled. Additional connections make R more ... connected with potential data sources and output

Read more »

Charting the Defeat of AV using R (and some ggplot2 and merge operations on top)

May 8, 2011
By
Charting the Defeat of AV using R (and some ggplot2 and merge operations on top)

In this post, I’ll be graphing some results from a recent referendum held here in the UK and combining it with the results of a set of local elections that were held at the same time. I’ll give some examples of graphing stuff using ggplot2 and will also show some info regarding merging datasets. At

Read more »

Is R an ideal language to teach the fundamentals of programming to beginners?

May 6, 2011
By
Is R an ideal language to teach the fundamentals of programming to beginners?

I’m helping out some colleagues learn programming from having zero experience with it in any shape or form. It’s quite a daunting task in some senses, because, well, it may not be easy! They are researchers, so they’ll need it for processing data and generating output, and perhaps processing BIG DATA at some point too.

Read more »

Loops, Conditionals and Variables: A Basic Simulation in R

May 3, 2011
By
Loops, Conditionals and Variables: A Basic Simulation in R

In this post, I’m going to go over some basics of using conditionals and loops in R. I’ll expand on the example I use here in future posts. The conditionals and loops will be used to create some dummy eye movement data. Background Before I get into the actual code itself, I should probably explain

Read more »