Wednesday, December 31, 2014

20 years of email



 



I started using email in 1994, on a Macintosh Plus, in a shared terminal room in the William Hardy building, Downing Site (Cambridge University). The Mac was used as a VT100 terminal emulator, connected via a serial link to the Cambridge Unix Service (CUS). The mail client, running on CUS, was PINE (originally released 1992). To mark the anniversary, I decided to go back to using PINE (well, ALPINE, as PINE was discontinued in 2005), this time running locally under OS X; alpine is available from MacPorts, and using IMAP and SMTP to access email on 1and1.co.uk. Frankly, it's a lot faster to use than any GUI-based system I've used since (simeon, Outlook Express, Outlook, Apple Mail, Thunderbird).

Saturday, December 20, 2014

Top 20 Psychology department

The REF2014 results are out. Over 80% of Plymouth Psychology's research outputs were assessed as internationally excellent or world leading, placing us in the Top 20 on this metric.  We managed to achieve this within a relatively modest research environment  (3.0 GPA). On a research efficiency measure, we came 3rd ( %age  of 3 and 4* outputs, divided by environment GPA, and excluding very small or selective submissions; FTE < 15).

Friday, November 21, 2014

Heraldic Homecoming

In the first 22 years of my life, I never met anyone with the surname "Wills" that I wasn't related to. In fact, there seemed to be considerable resistance to the idea that "Wills" was in fact a surname, with people regularly converting it to "Willis" or "Will".  Having recently discovered there are TWO Andy Wills on the lecturing staff of Plymouth University, I looked a bit further into the university records. There are 40 current students and 11 current staff called Wills. Oh, and there's a Wills presenting local TV news, too, and two at my daughter's shcool. I have the strange feeling that I may have accidentally come home, heraldically speaking :-)

Friday, November 14, 2014

First Neural Network simulation with RCpp (R / C++ integration)

My first look into using RCpp within R to speed up neural network simulations worked out reasonably well.

Starting with as-vectorized-as-possible R code (so, presumably, fairly optimal), my test simulation (100 runs of simulating 1,500 trials of the ALCOVE model, Kruschke, 1992; multiple runs are needed as trial order affects outcome) took about 22 seconds on my 2013 Macbook Pro. Converting the time-sensitive ALCOVE parts of the R code into C++ brought the run time down to less than 3 seconds,  for an approximately 8x speed up.

These are small gains in absolute terms, but become more significant when attempting multi-parameter optimization. This often requires hundreds of iterations. In initial tests, an optimization took about 8 minutes; in plain R the same optimization would have taken over an hour.

I think I should be able to get a further 8x speed up using snowfall and a faster workstation, bringing an optimization run down to around one minute. That's for another day, though.

Thursday, November 13, 2014

Adventures in RCpp

I spent yesterday looking into using C++ within R as an environment for neural network simulations (NNs are the classic case where iteration n+1 depends on the output of iteration n, so they do not vectorize easily and hence tend to be rather slow in plain R). R's RCpp package is intended to make R and C++ integration easy. Looking promising so far, but this cartoon Charlotte Edmunds showed me is particularly apt :-) http://xkcd.com/1445/


Thursday, October 2, 2014

Plymouth University in UK Top 20 for Research Quality

I guess we all like league tables when they make us look good :-). Here's a table that uses the Times Higher Citation scores to rank universities. Plymouth makes it into the UK Top 20 for the second year running, and is ahead of a number of notable institutions (including Exeter, Warwick, and Cardiff).


Rank University
1 Royal Holloway
2 Oxford
3 Cambridge
4 Sussex
5 York
6 Imperial College
7 Durham
7 Queen Mary
9 Edinburgh
9 King's College
11 St George's London
12 Bristol
12 UCL
14 Dundee
15 East Anglia
15 Glasgow
17 St Andrews
18 Plymouth
19 Southampton
20 Exeter
20 Lancaster
21 Liverpool
22 Brunel
23 Aberdeen
24 Manchester
24 Sheffield
27 LSE
28 Newcastle
29 Cardiff
29 Leeds
31 Warwick
32 Leicester
33 Hertfordshire
34 Birmingham
34 Nottingham
36 Portsmouth
37 Birbeck
38 Reading
39 Bangor
40 Aberystwyth
40 Queens Belfast
42 Stirling
43 Bath
44 Aston
45 Essex
na Heriot Watt
na Keele
na Loughborough
na L'pool John Moores
na Surrey


Friday, September 12, 2014

Twenty years of research

Twenty years ago this month I moved to Cambridge to start my Ph.D. with Ian McLaren.

Thursday, September 11, 2014

Automatic graphic file conversion (OS X)

There's a great command-line tool  for graphic file conversion called sips. For example, to convert all BMP files in the current directory to PNG files placed in a subdirectory you have made called 'pngs', just type:

sips -s format png ./*.bmp --out pngs

Of course, for 1-2 files, using Preview is probably just as quick, but for 10+ files, this can save a lot of time. I think imagemagick can do something similar on Linux, not sure about Windows.

UPDATE: In Linux, use e.g.

mogrify -format png *.jpg
 

Thursday, September 4, 2014

Bye Bye Virgin Media

My Virgin Media home broadband was looking a little out-of-date (3.6Mb/s download; 1MBs/s upload), and a 30 minute phone call with them ended with them saying this was the best service they could offer at my address. Kinda ridiculous as I'm in the centre of a city (Plymouth, UK). So, bye bye Virgin, hello BT. The new service kicked in this morning -- 63.6Mb/s download; 18.2MB/s upload ! Not only 18x faster that Virgin, but also 2-6x faster than my WiFi connection at Plymouth University!

Monday, July 28, 2014

Critical thinking

Just received the student feedback for some lectures I gave in Term 1 - this was the first half of a new Year 1 course in critical thinking, so I was particularly interested to see it. About 10% of those who responded to the survey felt the delivery and/or sequencing of material could be better.  I have some plans to address that. It was nice to see a similar number actively praising the course - not something I necessarily expected given the topic.

Friday, July 4, 2014

Show all files in OS X Finder

There are various guides to this around, but most do not result in the hidden folders in the root directory (Macintosh HD) being shown. This works, though: sudo chflags -R nohidden /*


Wednesday, July 2, 2014

LaTeX to Microsoft Word

I've been using LaTeX for over a year now, and definitely prefer it to Word - I find it much easier to concentrate on content with its WYSIWYM rather than WYSISYG approach. Of course, most of the rest of psychology (and the world) continues to use Word, so it's harder to share content with co-authors than if I were still using Word.

Fortunately, latex2rtf provides a great solution. It auto-converts latex to an RTF file, which can then turned into a variety of formats (including DOC or DOCX) by your word processor of choice.

Now I have latex2rtf working, it's very easy to use, but getting it working was a bit of a pain. Some notes below that others may find helpful (these notes have been updated):

  1. There is no installation package for Mac OS X on latex2rtf's webpage. However, it is available on https://www.macports.org/. Install MacPorts, and then install latex2rtf with the command: sudo port install latex2rtf.
  2. Recently, I've been using the excellent elsarticle document class in LaTeX. latex2rtf does not seem to recognise this. So, to get referencing to work properly in latex2rtf when using elsarticle, you need to explicitly put the line: \usepackage{natbib} into your .tex file. This single addition fixes referencing.
  3. In OS X, open a Terminal window, use cmd-drag to change the Terminal's directory to where your .tex file is, and simply type latex2rtf <filename>
  4. latex2rtf assumes you have already processed your tex file (e.g. to PDF) and the relevant support files this creates. still exist in the directory.

Wednesday, May 28, 2014

Inkscape - Free vector graphics program

Vector graphics are great for producing high-quality illustrations for journal articles, but the programs I've used to date are either really expensive (Corel Draw, Adobe Illustrator) or rather limited (MS PowerPoint). So, today I tried Inkscape, a free, open-source, cross-platform vector graphics program. It seems pretty good and easy to use. Note that, on a Mac, keyboard shortcuts for this program use Ctrl rather than the more usual Cmd.

Friday, May 23, 2014

Bayesian contingency chi-square in R


One of the advantages of Bayesian statistics is that they permit discussion of null results. Antony Overstall of St. Andrews has recently released a package for R called conting that handles Bayesian analysis of contingency tables in a relatively straightforward way. http://cran.r-project.org/web/packages/conting/ . I had a play around with it and managed to get meaningful results in about an hour. Take a look!

Wednesday, May 21, 2014

Free teaching materials

Some of my teaching materials are now freely available on willslab.co.uk  Currently, you'll find some tutorials on R, a suite of software for 1st year practicals, and a formula booklet for first year stats courses. I'll add more when I have the time.

Tuesday, May 20, 2014

Some sobering statistics about psychological data

I've been catching up on some of the recent articles that have dealt with data quality issues in psychology. Here are three sobering statistics:

  1. By some estimates, only about 1% of papers published in psychology since 1900 have involved replications (Makel et al., 2012).
  2. Under certain not unreasonable assumptions, approximately one-third of published results in psychology may be false positives (Pashler & Harris, 2012).
  3. Even for recently published papers, approximately 70% of requests for raw data end in failure (Wicherts et al., 2006).
So, if your research depends on a previous result (and whose doesn't to some extent?), start your experiment series with a direct replication, and publish your raw data.

Friday, May 16, 2014

Travel website with office hours! a.k.a. Only In Academia

Trying to book a flight with the university's travel agent. It's already taken two days to get my budget code back on to their system. Today, I almost book a flight, but my passport is at home and I can't complete the booking without it. No worries, I think. I'll just make the booking when I get home. No chance. Clicking on my choice of flight, the website tells me I cannot proceed with this option because it is out of office hours. What, so the computers get to go home in the evenings !?!

Saturday, February 22, 2014

Publicity of Oxygen

OK, so O2 mobile phone company, you just lost my business for life. Just spent 45 minutes on hold on a premium rate number (0844, 5p/minute). When I got through, I said "I've been on hold for 45 minutes, and my battery will go at some point, so if you can just give me my PAC number a.s.a.p, that'd be much appreciated". The response, "It'll take as long as it takes" and she then ploughed through an interminable tedious written script. In the end, I had to ask for the PAC at least four times before they actually gave it to me.

I can't understand the mentality of a company that wants to make this process so time consuming and irritating. If a customer is asking for a PAC number, they've already decided to leave you. All you can achieve by making the process long winded and irritating is to ensure you never ever get them back. Why on earth is it not possible to request your PAC online !!!