Andriy's blog

Using text mining in R for a pharmaceutical product search through provincial formularies in Canada

From time to time I have to check whether one or another pharmaceutical product is reimbursed on a public formulary in Canada. A usual routine is to go on each provincial formulary web site and search either via an online query tool or in a PDF printout of the formulary. One or two drug products make it easy to search across 10 different formularies. However, for a portfolio of 10 products I would rather search only Ontario and Quebec agencies (which probably cover 2/3 of Canadian public) as it is time consuming. And how about searching for 100+ products?

Import XML data in R

It is hard to say how I ended up on a website for orphan diseases. A site http://www.orphadata.org allows to access a few files with orphan disease data (epidemiological, clinical and genetic) in XML format. XML data are easy to convert in a spreadsheet using MS Excel in Windows but LibreOffice on linux kept returning an error message. Another option would be to write an XSLT file to convert XML data into another format. Luckily, there is also a library in R for direct import from XML files.

R script for a Markov model

Excel spreadsheet is probably the most popular medium for implementing Markov models. I learned the approach from a step-by-step guide by Damon Douglas (published through Knol, a service from Google and now discontinued). I tried to translate the guide into a script for R. Any comments or suggestions for improvement are welcome.

horizon<-10 # model horizon (years, days, whatever)
n=1000 # population size for a population matrix
sim_n<-1000 # number of simulations
n_strat<-2 # number of strategies
n_states<-3 # number of states

First experience with Drupal

I have spent a few days considering Wordpress vs. any other content management system (like Drupal) as a platform for a website. The ease of use is a very attractive feature in WordPress. However, a future scalability and security prevailed, and Drupal is my new friend. The site is spartan at this moment as 'Zen' theme is the easiest way to layout content for mobile devices without professional help. A stylish template might have helped impress the visitors but I never go to other websites. I pull all content to Google Reader via RSS anyway.

Subscribe to RSS - Andriy&#039;s blog