Posts in 'text'

Implementing annotation-free quantification of splice junction usage via RNA-STAR and Python+Pandas magic

If you’ve been reading my blog for general python/productivity stuff, you are in for a TREAT! Here is some REAL SCIENCE! I’ll give a quick intro but please let me know if anything is unclear. I spend most of my time talking to a few people who …

PYTHONPATH is a liar. site.py and easy-install.pth tell the truth

Lately I’ve been working in virtualenvs which as been great for developing but not so great for installing. I’ve run into numerous issues where I prepend my PYTHONPATH with the directory I want to get imported first, but to no avail. You’ve run into this: you export …

Most of the time, you fail

This year, I only applied to two fellowships: Hertz and Paul and Daisy Soros. And I didn’t even get to the interview stage of either of them. But I’m gonna keep on trucking. After all, it’s grit and determination that lead to success. So I’ll have …

Prettyplotlib update!

Check it out!

Major changes:

  • Don’t have to supply ax object to everything
  • All functions return an ax object (let me know if this is not true!)
  • Added fill_between and fill_betweenx
  • pcolormesh accepts center_value keyword argument (‘kwarg’) to re-center diverging colormaps
  • Don’t change rcParams upon import, do everything …

You can code, too!

Recently, I’ve had several conversations with biologists who know they should probably learn to code, but the whole concept is so daunting and they’re too busy with their research anyway. I’ve tried to convince them to pursue programming, not just because it’ll make their research analyses …

Succinct loop testing in Python

Since I’m a data scientist and all, my datasets can be too big to deal with when I’m initially testing an idea. So to test a for loop in Python with just a few examples, I used to do this kind of stuff:

n = 0
for thing in …

Everything is a performance: Make your fifteen minutes count

Musicians, actors, dancers, and other performers know how much preparation and practice goes into their few minutes (or a few hours) of actual performing. Consider a single dancer in a 1.5 hour performance. A professional 25-year-old dancer has probably been dancing since they were around 5, and they’ve …

UCSD Scientific Python User Group

Some of us grad students at UCSD who use primarily Python for our scientific research have created a user group, UCSD Scientific Python User Group. If you’re interested, check out the github account and add yourself to the google group:

  • Github: https://github.com/ucsd-scientific-python/user-group
  • Google groups: ucsd-scientific-python …

prettyplotlib: Painlessly create beautiful matplotlib plots

A while back I wrote a few tutorials about how to work with Python’s plotting library, matplotlib, so that it behaves nicely and produces beautiful plots. Well, I got tired of tweaking every single figure individually so I wrote this library, prettyplotlib to have pretty default plots in Python …

The R script that will change your life

If you use the R programming language, you probably know how much of a pain it is to keep your packages updated. You’ve run update.packages(...) on the few that you want to keep up to date, but it’s a pain in the neck to do that for …