22 May 2014


#writing with Markdown: Installing <em>knitcitations</em> package

#writing with Markdown: Installing knitcitations package

Installing bits

Knitcitations is an R package that allows us to write manuscripts or web pages complete with the citations and bibliography. Kind of JabRef or EndNote. With this tools we can write a complete document or even a thesis with #Markdown. I use Linux Ubuntu 13.10 and R 3.1.0.

First check if your development library in your system is complete. I'll explain why we need this zero step later.

Step 0: open your Terminal window and type

sudo apt-get install libcurl4-openssl-dev libxml2-dev

This step should install your Linux Delopment library.

Step 1: install the packages

Open your R Studio and run

  1. install.packages("knitcitations") or

  2. install.packages("~/Downloads/knitcitations_0.5-0.tar.gz", repos = NULL, type = "source") # to install from source "tar.zip" format

If any of both commands not working (I don't really know why), then we have to build the package from source. So to do this you have to install “devtools” package and you need to have a complete Linux development library.

So you need run this command

  1. install.packages("devtools") # to install R development tools then

  2. install_github("knitcitations", "cboettig") # to install the package directly from _cboettig's_ Git Hub account

Both above commands will look for the development library that you've installed on the previous step. It should work nicely. I hope, because I've followed several discussion on the net then the errors pop mostly because your system don't have the required library.

Real example of using Knitcitations

I'll post my update later on based on an example from my manuscript.

References:

No comments: