alyssafrazee / polyester

Bioconductor package "polyester", devel version. RNA-seq read simulator.
http://biorxiv.org/content/early/2014/12/12/006015
90 stars 51 forks source link

typically, dispersion = 1 / size #3

Closed mikelove closed 10 years ago

mikelove commented 10 years ago

Typically dispersion of a negative binomial is 1/size for the size arg of the rnbinom function.

This way, for fixed mu, larger dispersion corresponds to larger variance.

If you accept this change you'd have to fix the man pages for NB and simulate_experiment.

mikelove commented 10 years ago

admittedly not 'typical' enough for rnbinom man page :)

alyssafrazee commented 10 years ago

Great point. We'll think about this a bit more: on the one hand, I think it makes a lot of sense to call 1/size the dispersion parameter, for the reason you mention (increased dispersion --> increased variance). On the other hand, I'd like to stay consistent with rnbinom.

mikelove commented 10 years ago

yes, it's unfortunately inconsistent. DESeq, edgeR, Cuffdiff / CummeRbund, baySeq use disp=1/size though, so you might want to warn users.

alyssafrazee commented 10 years ago

Parameter has been re-named to "size" via this commit to avoid confusion with dispersion parameterization. Thanks for the suggestion!