A bookmarklet for the Guardian quick crossword

I’ve been doing the Guardian quick crossword with my colleagues since starting my PhD back in 2012. Eventually, crossword mania took us and we started doing crosswords in the afternoon as well as in the morning. This necessitates printing ‘back issue’ crosswords, which in turn makes getting to those crosswords on my phone1 a little harder than getting to today’s crossword.

It eventually occurred to me that I could create a bookmarklet which would pop up a dialogue asking for the number of the crossword we were doing, and would then take me to that crossword’s page. It’s a bit niche, but the JavaScript for this bookmarklet is below, just in case anyone else finds it useful.

javascript:N=prompt('Quick crossword no','');if(N){location.href='http://www.theguardian.com/crosswords/quick/'+escape(N)}

It should be noted that if you don’t input a number, or you hit cancel, then nothing happens. If you want to be taken to the Guardian’s crossword page instead, then you can add the following code to the end of the bookmarklet.

else{location.href='http://www.theguardian.com/crossword/quick'}

  1. We don’t cheat, we just check our answers. Honest. 

Unpacking .pkg files in OS X with BetterZip

I had cause today to try to unpack a .pkg file. I had installed PDF File Unlocker and found it was a bit pants1. Unfortunately, it installed from a .pkg file and there was no uninstaller or list of files that get installed, so I wanted to make sure I’d efficiently purged it from my system.

I have BetterZip, which is a really good utility for unzipping basically any file on the planet for OS X. I will just note at this stage that I have an older version of the utility and I haven’t upgraded to BetterZip 2, but I’ve got a lot of use out of the app. The below steps rely on having BetterZip. If you’d like to do it without BetterZip, I found this blog post and this Stack Overflow post to be very helpful in informing my actions.

  1. Change the extension from .pkg to .xar.
  2. Open the file with BetterZip. This took a while on my system but did eventually work.
  3. Three files should appear: Payload, Bom, and PackageInfo.
  4. PackageInfo: Just open this in your favourite text editor.
  5. Payload:
    • Add the extension .cpio.gz.
    • Open the file with BetterZip.
  6. Bom:
    • Open Terminal.
    • Navigate to the file.
    • lsbom Bom

Hopefully that all helps somebody else, too!


  1. If you generate a PDF with the free trial, it’ll be the first half of the PDF and every time you open it Adobe Acrobat will give you a little pop-up window. I disliked it. 

Facebook and their psychology experiment

Today it was reported by the AV Club that Facebook (or their researchers) has recently submitted a paper to a journal of psychology exploring the impact of social media on mood. It’s actually quite an interesting finding, if perhaps an expected result: people get happier or sadder depending on whether the mood of their news feed is light or heavy.

But the ethics are a bit problematic. Facebook conducted this experiment by skewing users’ feeds to either be more positive or more negative and then seeing whether future posts from a user were likely to be more negative or positive as a result. This means that they manipulated users’ emotions, which is somewhat concerning. It’s entirely legal under the terms of the agreements you make with Facebook when you open an account, but is it ethical? After a conversation with my girlfriend, I rather think not: informed consent is the key thing here, and the users in this experiment did not give informed consent despite any agreements they might have clicked ‘OK’ on.

What really interests me, however, is the question of utility. There’s an argument that if Facebook can make its users more happy by manipulating their feed, then they should. But what this exposes is the question of whether Facebook is an information service or an entertainment service: is the primary goal to keep you updated about your friends and what they’re doing, or is the primary goal to entertain your users and make them happy? This research makes me think Facebook is more interested in the latter, compared to Twitter, which seems to focus more on the former1. That’s potentially an insight into Facebook’s goals and what they’re aiming to do in the future.

The thing I’m most curious about isn’t the utility but rather the way in which the experiment was conducted. I don’t get why Facebook used the methodology they did. They manipulated the feed to give more positive and more negative messages and measured the change in mood of the resulting status updates: that’ll get you the results you want, sure. But why not the following methodology?

  1. Choose a user.
  2. Let the existing algorithms automatically generate that user’s feed.
  3. Monitor those algorithms’ output over a month and determine the average happiness of their feed and their statuses.
  4. Keep monitoring, but now looking for a period of time which deviates from the average happiness by some amount.
  5. Upon measuring this, measure the change in happiness of status posts.

It would surely allow researchers to explore the same question but without actually needing to manipulate users’ emotions at all, thus neatly removing any ethical qualms whilst still allowing interesting research to be conducted. The level of happiness might be hard to quantify, but they’ve already quantified it in the study so I don’t see that as a huge stumbling block. Is there a flaw I’m not seeing here, and if so, what is it?

Edited on 29 June 2014: Thanks to the commenters for their intriguing discussion of this idea! A lot of people have pointed out that this is not the equivalent of an intervention study; this has been noted both in the comments on this piece and by @tedsvo and @masnick (who wrote a follow-up to my blog post talking about my idea) on Twitter.

I’m aware that this is the case, but my background is in solar-terrestrial physics and so none of my research can be based on intervention studies. As a result, the scientists in my field have to develop techniques to explore causality based on observed correlations. What I’m essentially proposing, above, is a superposed epoch analysis in which users’ happiness is expressed for a number of days on either side of observed impacts on newsfeed positivity. It isn’t as definitive as Facebook’s method, but it is a more ethical way to conduct research which would hopefully shed light on the questions at hand.

I would be fascinated to see whether the same result could be reached using a non-intervention-based method, and I wonder whether the advent of large datasets from companies like Facebook and Google could be an opportunity for physicists to utilise data analysis skills over large timescales?


  1. This might also be why businesses are starting to find their outreach on Twitter is much more effective than on Facebook: Facebook is focusing on users to the detriment of businesses posts appearing in feeds, whereas Twitter isn’t doing quite the same thing. (Both companies allow sponsored posts so the monetisation strategy is equal between the two.) 

Procrastinations #13

The cover of Procrastinations #13, showing a member of convention staff literally burned from the shoulders up.

Procrastinations #13 is finally here! Featuring contributions from myself, Claire Brialey, Meg Frank, Crystal Huff, and Hannah Peaden, I’m excited to be able to share it with you all. This issue’s theme was convention burnout, and you can download it now!