<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
<channel>
  <title>Andrew Cook on scriptogr.am</title>
  <link>http://andrewcook.org</link>
  <description> </description>
  <pubDate>2012</pubDate>
 
  <item>
    <title>The New iPad</title>
    <pubDate>Thu, 08 Mar 2012 09:33:00 -0500</pubDate>
    <link>http://andrewcook.org/post/the-new-ipad</link>
    <guid>http://andrewcook.org/post/the-new-ipad</guid>     
    <description><![CDATA[<p>Being an iOS developer, I got an iPad as soon as they became available in the UK. For about three months it had the best screen I'd ever seen - then I got an iPhone 4 and suddenly the iPad pixels became very visible.</p>

<p>About that time I also ran out of space - I could no longer put everything I wanted on the device. This problem has only got worse, as apps (including mine) get bigger.</p>

<p>So that set one of my criteria for upgrading my iPad. Any upgrade had to have either 
* A Retina Display
* More than 64GB of storage</p>

<p>and ideally both.</p>

<p>Apple's announcement yesterday means I'll be upgrading to that lovely retina display - but the lack of a 128GB storage option is rather disappointing. I guess this time next year I'll be debating the need to upgrade for that extra space.</p>
]]></description>
  </item>
 
  <item>
    <title>Chilly Graveyard</title>
    <pubDate>Sun, 26 Feb 2012 10:22:00 -0500</pubDate>
    <link>http://andrewcook.org/post/chilly-graveyard</link>
    <guid>http://andrewcook.org/post/chilly-graveyard</guid>     
    <description><![CDATA[<p><a href="http://500px.com/photo/5187265"><img src="http://pcdn.500px.net/5187265/502ef0a17467577229487f17a3f620fa7391e92f/4.jpg" alt="Graveyard by ajcook  on 500px.com" border="0" style="margin: 0 0 5px 0;"><font style="font-size: 120%;"><a href="http://500px.com/photo/5187265">Graveyard</a> by <a href="http://500px.com/ajcook">ajcook</a></font></p>

<p>This graveyard was taken a couple of hours after I photographed <a href="http://andrewcook.org/post/a-local-church">the church</a> below.</p>
]]></description>
  </item>
 
  <item>
    <title>A Local Church</title>
    <pubDate>Sun, 26 Feb 2012 10:22:00 -0500</pubDate>
    <link>http://andrewcook.org/post/a-local-church</link>
    <guid>http://andrewcook.org/post/a-local-church</guid>     
    <description><![CDATA[<p><a href="http://500px.com/photo/1339831"><img src="http://pcdn.500px.net/1339831/5523e0866e35e651c3bac968db8ca8bf6128c656/4.jpg" alt="St John the Baptist Church. North Baddesley, Hampshire by ajcook  on 500px.com" border="0" style="margin: 0 0 5px 0;"></a><font style="font-size: 120%;"><a href="http://500px.com/photo/1339831">St John the Baptist Church. North Baddesley, Hampshire</a> by <a href="http://500px.com/ajcook">ajcook</a></font></p>

<p>It's chilly again. I took this picture, and the next below, in January 2010 at a rural Hampshire church. At the time it was a particularly harsh winter, with a solid frost all over. I turned up at the church just before dawn. This one was taken as the sun came up. The photo of <a href="http://andrewcook.org/post/chilly-graveyard">the graveyard</a> a couple of hours later.</p>
]]></description>
  </item>
 
  <item>
    <title>Spotlight Importers and the Mac AppStore</title>
    <pubDate>Mon, 20 Feb 2012 18:55:00 -0500</pubDate>
    <link>http://andrewcook.org/post/spotlight-importers-and-the-mac-appstore</link>
    <guid>http://andrewcook.org/post/spotlight-importers-and-the-mac-appstore</guid>     
    <description><![CDATA[<p>I've just updated <a href="http://recruitmentmodeller.com">Recruitment Modeller</a> with a <a href="http://en.wikipedia.org/wiki/Spotlight_(software)">Spotlight Importer</a>.</p>

<p>I thought it'd be reasonably simple - just create the importer as a sub project of Recruitment Modeller, sign it, and copy it to the right place (./Library/Spotlight) when building the main app.</p>

<p>It's not so simple. It's vital <em>not to sign</em> the Spotlight importer (or I presume similar embeded binaries such as quicklook plugins) or you get an invalid binary warning when you upload to the AppStore.</p>

<p>Having realised that, the new version of Recruitment Modeller is now waiting for review.</p>
]]></description>
  </item>
 
  <item>
    <title>The timing of clinical trials</title>
    <pubDate>Tue, 07 Feb 2012 03:55:00 -0500</pubDate>
    <link>http://andrewcook.org/post/the-timing-of-clinical-trials</link>
    <guid>http://andrewcook.org/post/the-timing-of-clinical-trials</guid>     
    <description><![CDATA[<blockquote>
  <p>"All trials are in the past, all patients to whom the results will be applied are in the future."</p>
</blockquote>

<p>A very true statement from Richard Peto - which must have implications for the generalisability of trials. We take alot of effort to make sure they're appropriately generalisable to the present day population of interest - but can pay less attention to how relevant they will be once the results are available.</p>
]]></description>
  </item>
 
  <item>
    <title>Showing an NSPopover from an NSToolbarItem</title>
    <pubDate>Thu, 26 Jan 2012 00:00:00 -0500</pubDate>
    <link>http://andrewcook.org/post/showing-an-nspopover-from-an-nstoolbaritem</link>
    <guid>http://andrewcook.org/post/showing-an-nspopover-from-an-nstoolbaritem</guid>     
    <description><![CDATA[<p>It's not unreasonable to want to show an NSPopover from an NSToolbar - probably originating from an item on the toolbar - like this:</p>

<p><img src="http://falu.co.uk/images/blogImages/PopoverFromToolbar/showingPopover.png" alt="Popover from Toolbar Item" title="A Popover" /></p>

<p>Unfortunately, showing a popover in Cocoa relies on the method</p>

<pre class="prettyprint"><code>-(void)showRelativeToRect:(NSRect)positioningRect ofView:(NSView *)positioningView preferredEdge:(NSRectEdge)preferredEdge
</code></pre>

<p>but as NSToolbarItem inherits from NSObject rather than NSControl (which was possibly a sensible design decision 20 years ago) there's no easy way to get the NSToolbarItem's view - and hence to show the popover from the right place.</p>

<p>The trick is to put an NSButton inside the toolbar item, then use a property to keep track of it, and get its bounds when clicked. The code looks something like :</p>

<pre class="prettyprint"><code>@property (nonatomic, strong) IBOutlet NSToolbarItem *showPopoverToolbarButton;
</code></pre>

<p>and</p>

<pre class="prettyprint"><code>NSView *viewToShowFrom = [self.showPopoverToolbarButton view];

PopverDetailViewController *pdvc = [[PopoverDetailViewController alloc] initWithNibName:@"PopoverDetailViewController" bundle:nil];

self.popover                       = [[NSPopover alloc] init];
self.popover.contentViewController = pdvc;
self.popover.delegate              = self;
[self.popover showRelativeToRect:[viewToShowFrom bounds] ofView:viewToShowFrom preferredEdge:0];
</code></pre>

<p>And there's one more thing. As presented, when clicked the toolbar item will show a nasty light square around itself, like this:</p>

<p><img src="http://falu.co.uk/images/blogImages/PopoverFromToolbar/highlight.png" alt="Nasty Light Square" title="Showing an unwanted hightlight" /></p>

<p>You can get rid of this by changing the button cell type to <em>Momentary Change</em> using Interface Builder.</p>

<p><img src="http://falu.co.uk/images/blogImages/PopoverFromToolbar/popover.png" alt="IBPopover" title="Changing the button type" /></p>
]]></description>
  </item>
 
  <item>
    <title>FoCaL</title>
    <pubDate>Mon, 16 Jan 2012 00:00:00 -0500</pubDate>
    <link>http://andrewcook.org/post/focal</link>
    <guid>http://andrewcook.org/post/focal</guid>     
    <description><![CDATA[<p><a href="http://www.reikan.co.uk/focal/" title="FoCal Software">FoCal</a> is some potentially useful software which performs focus <a href="http://www.learn.usa.canon.com/resources/articles/2011/af_microadjustment_article.shtml">microadjustment</a> for some Canon cameras, automatically. The obvious major flaw is that it's currently Windows only, but the developer has promised a Mac version in future - and if you buy a key for the Windows version now he says that it'll work later for the Mac.</p>

<p>Having bought the Windows version, the next challenge was how to run it on my MacBook. It turned out there was only one answer - Boot Camp. While FoCaL ran in virtual machines on both VMWare Fusion and Parallels, it couldn't see my 7D. I don't think that's FoCaL's fault, as Canon's EOS Utility couldn't either. I blame the virtual machine software. In summary - neither VMWare or Parallels are up to the job, so Boot Camp it was.</p>

<p>FoCal wouldn't start until it had updated .NET - even though I'd just updated it from the Microsoft website. For someone who usually uses Mac software, running software designed for Windows was rather a shock. I'd forgotten how clunky, and frankly how ugly, Windows software can be.</p>

<p>And so to the FoCaL interface - which is functional, but plain. It lags a bit and is a touch unresponsive (on a MacBook Pro, 2.66 GHz i7, 4GB RAM), but that could possibly be put down to running inside .NET.  The buttons are big - but the text is small. It does seems like that would be a simple interface issue which could be improved.</p>

<p><strong>But does it work? - It appears that it does.</strong></p>

<p>I set out to calibrate lenses for my 7D using the plus version of FoCaL. Using the provided target, printed on an inkjet, it's easy enough to position a camera on a tripod. It's then just a matter of hitting the autocalibrate button, and off it goes. Around three minutes later it's diagnosed what the appropriate adjustment should be, and offers to reprogramme the camera.</p>

<p>I calibrated 5 lenses, ranging from focal lengths of 15mm to 250mm in less than half an hour - and they all appear to be getting better focus.</p>

<p>So - the software seems to work. It's just very unfortunate you need to use Windows (and a real Windows installation, not a virtual machine) to run it.</p>
]]></description>
  </item>
 
  <item>
    <title>Installing Windows 7</title>
    <pubDate>Sun, 15 Jan 2012 00:00:00 -0500</pubDate>
    <link>http://andrewcook.org/post/installing-windows-7</link>
    <guid>http://andrewcook.org/post/installing-windows-7</guid>     
    <description><![CDATA[<p>I thought I'd give <a href="http://www.reikan.co.uk/focal/" title="FoCal Software">FoCal</a> a go. FoCal is some potentially useful software which performs focus microadjustment for some Canon cameras, automatically. The obvious major drawback to FoCal is it's currently Windows only software - and that meant installing Windows on my Mac.</p>

<p>Luckily, I had a copy of Windows 7 lying around from a few years ago, and due to a problem with virtual machines, I've had three goes at installing Windows in the past week - once into a <a href="http://www.reikan.co.uk/focal/" title="Parallels">Parallels virtual machine</a>, once into a <a href="http://www.vmware.com/products/fusion/overview.html" title="VMWare Fusion">Fusion virtual machine</a>, and once into a partition on a MacBook Pro via <a href="http://www.apple.com/support/bootcamp/" title="Apple Boot Camp">Boot Camp</a>.</p>

<p>Why is the Windows installation experience so poor? I know it's something people don't do very often - and most people don't do at all - but it's not a good first impression.</p>

<p>I really don't get why Windows still has to reboot when it finds new drivers - but not all the time. And why the inevitable set of updates after a new installation also require multiple reboots. One, to make sure all the fresh code is loaded, sure. But why more than one?</p>

<p>BeOS had this right over a decade ago. MacOSX gets it right. Linux, while challenging as a desktop OS, doesn't have to reboot for updates at all.</p>
]]></description>
  </item>
 
  <item>
    <title>Eye of the Rhino</title>
    <pubDate>Mon, 02 Jan 2012 00:00:00 -0500</pubDate>
    <link>http://andrewcook.org/post/eye-of-the-rhino</link>
    <guid>http://andrewcook.org/post/eye-of-the-rhino</guid>     
    <description><![CDATA[<p><a href="http://500px.com/photo/4264529"><img src="http://pcdn.500px.net/4264529/55e9cbcd0b57f286eff6eaba57c169c9eadd57ad/4.jpg" alt="Eye of the Rhino by ajcook  on 500px.com" border="0" style="margin: 0 0 5px 0;"></a><font style="font-size: 120%;"><a href="http://500px.com/photo/4264529">Eye of the Rhino</a> by <a href="http://500px.com/ajcook">ajcook</a></font></p>

<p><a href="http://www.marwell.org.uk" title="Marwell Wildlife">Marwell Zoo</a> has a collection of three <a href="http://en.wikipedia.org/wiki/Rhinoceros">rhinos</a>, who I guess are reasonably happy with their lot. I came across them (unusually) indoors, and rather close.</p>
]]></description>
  </item>
 
  <item>
    <title>Society for Clinical Trials Meeting, May 2011</title>
    <pubDate>Thu, 22 Dec 2011 00:00:00 -0500</pubDate>
    <link>http://andrewcook.org/post/society-for-clinical-trials-meeting-may-2011</link>
    <guid>http://andrewcook.org/post/society-for-clinical-trials-meeting-may-2011</guid>     
    <description><![CDATA[<p>In December 2010 I was fortunate enough to have a proposal for an oral presentation accepted for the 32nd Society for Clinical trials meeting in Vancouver, Canada. So in May 2011 off I went for 4 days of conference and a pre-conference workshop.</p>

<p>The <a href="http://sctweb.org" title="SCT">Society for Clinical Trials</a> is an international organisation dedicated to the development and dissemination of knowledge about the design, conduct and analysis of clinical trial methodologies - rather like HTAi but with a focus on clinical trials rather than systematic review. Despite its claim to be international its meetings are almost always in North America - of those 32 meetings 1 has been in London and one in Brussels. The attendance this year reflected a similar pattern with 600 attendees, of whom less than 100 were not from either the USA or Canada. Of those 100 however, there were several HTA grant holders, and at least one Commissioning Board member.</p>

<p>I started off with a pre-conference workshop on Adaptive Clinical Trials, delivered by Roger Lewis (an Emergency Physician from UCLA), and Jason Connor (a statistician from a private consultancy, and the University of Central Florida). This mix was reflected in the rest of the conference, with people from Universities and public funders mixing with those doing trials in industry and Contract Research Organisations (CROs) - a type of organisation I only found out about at this conference.</p>

<p>There then followed 3 days of insight about other people’s experience in designing and delivering trials in both the public and private sector. Possibly the most eye-opening session was one on The CATT trial - the North American equivalent of our IVAN trial. They relayed a horrific story of the interactions the trial team had had to have with health insurance companies and Medicare (the federal health insurance system for pensioners) in order to get the drugs to patients. A particular problem had been with the co-pay system that Medicare uses. Rather than a flat prescription charge, people on Medicare pay a percentage of the retail cost of a prescription, with one drug having a co-pay of $10 and the other a co-pay of $100, the bills received would have rapidly unmasked the study. The effort required to overcome these issues was gargantuan, and puts our challenges with excess treatment costs into perspective.</p>

<p>This was a high quality conference. Of all the sessions I went to, only one was less than excellent - and that was because the clinician involved in the session had had his aeroplane diverted, so the unfortunate statistician who did manage to get there had to try to relay the clinical importance and effects of the various cancer treatments discussed.</p>

<p>It’s a conference which you may consider worth targeting, for presentation of RoR projects with a particular clinical trial bent. I certainly hope I’ll be able to go again. It’s held every May, with the abstract submission deadline the previous December.</p>
]]></description>
  </item>
    
</channel>
</rss>
