Archive For July 26, 2016

getting lists of rRNA, miRNA in R

By |

Recently i had to remove all small RNAs from some cufflinks data. There are lots of way to do this, but this was relatively painless (aside from figuring it out). The HUGO website has subcategories of genes annotated and we can grab the data from there. It’s available as both JSON or TEXT. I found…

Read more »

Enable X on AWS EC2 instance

By |

Spin up an EC2 instance. For this demo, I used an t2.micro instance with the base amazon Linux AMI. First connect to our machine. You need to find your EC2 instance public dns. It will be something like: ec2-1-2-3-4-us-west-1.compute.amazonaws.com. The user is always ec2-user. ssh -i /path/to/pem_file ec2-1-2-3-4-us-west-1.compute.amazonaws.com Once on the EC2 machine, I needed…

Read more »

Accessing biomart from R

By |

A good use for Ensembl’s biomart is the ability to pull a list of gene names linked to ensembl transcript ID’s, as when using Sleuth. We will need Bioconductor and the biomaRt library if you don’t have it already

The usual bioC way of doing things like this is to create an object that…

Read more »

How to view function definitions in R (S3/S4)

By |

Typically, when you type the name of a function in R, it will show you the source code of that function. For example, to see the definition of the ls() function, simply type ls into the R IDE. Viewing S3 methods Some functions work by dispatch. An example is print(). When you call print()with some…

Read more »