Posts tagged 'python'

Teaching “Data cleaning”

Our compute cluster is down for maintenance, so obviously instead of working on my advancement exam presentation, I’m gonna write a blog post about teaching “data cleaning” to graduate students in UCSD’s BIOM 262: “Quantitative Methods in Genetics” class, where I taught Python, IPython Notebook, and pandas, using Software Carpentry techniques for teaching technical skills.

No longer actively developing prettyplotlib

It is with heavy heart that I announce that I am no longer actively developing prettyplotlib. I just don’t have the bandwidth available to do the project justice. It was a fantastic experience to …

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 …

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 …

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 …

Beautiful boxplots and sassy small multiples

Last week, I posted about implementing design principles in Python’s graphic library, matplotlib. I received lots of great feedback, and made another tutorial, specifically about boxplots and “small multiples”. Small multiples are a concept coined by Edward Tufte about having many plots using the exact same axes, allowing the …