Archive for category: Programming

The wings of a programmer

12 Apr 2015
2015/04/12

Programmers think programming is really hard.  Non-programmers think it’s even harder than that.

Figure 1: The perceived difficulty of programming. perceived_programming_difficulty

Why is programming so arduous? Read more →

The TaoTeProgramming R package

29 Jun 2014
2014/06/29

I’d like to do a song of great social and political import.

The code that created the illustrations in Tao Te Programming is now available as the TaoTeProgramming package on CRAN.

The sea is just flat hills

sea51hills5 And they are both just smooth mountains.

Read more →

Blog recap of 2013

31 Dec 2013
2013/12/31

Posts by page views

  1. Interview with a forced convert to R from Matlab
  2. A first step towards R from spreadsheets
  3. Plot ranges of data in R
  4. A statistical review of ‘Thinking, Fast and Slow’ by Daniel Kahneman
  5. The 3 dots construct in R
  6. Translating between R and SQL: the basics
  7. An R debugging example
  8. R database interfaces
  9. R and social media
  10. On the acceptance of R
  11. The joy of data analysis
  12. The options mechanism in R
  13. A corner on convenient data analysis
  14. Living it up with computational errors
  15. Bricks not monoliths
  16. 100 savvy sites on statistics
  17. The AllTrials campaign

Views at other sites are not included — that is, views at R-bloggers and statsblogs.

This ordering gives an unfair advantage to posts that were written early in the year. Read more →

Bricks not monoliths

06 Feb 2013
2013/02/06

Chapter 32 of Tao Te Programming advises you to make bricks instead of monoliths.  Here is an example. The example is written with the syntax of R and is a data analysis, but the principle is valid no matter what language you use or what your task is.

Monolith

Here is an outline of a function  reminiscent of many novice attempts:

monolith <-
function (data, col="blue", pch=21) 
{
        # transform data
        # fit model to data
        # plot data, uses 'col' and 'pch'
        # get desired model results
        # return desired model results
}

Each of these comment lines may be many lines of code so that the whole function runs to pages. Read more →

© Copyright - Burns Statistics