compiler and runiregGibbs (bayesm)

April 13, 2011
By

[This article was first published on [the] joint posterior distribution, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

So everyone’s excited about the new R 2.13 release because of the compiler package.
Apparently it is easy to get a 3x speed increase by simply compiling a function.
Doing a lot of the MCMC stuff, I am particularly excited about speed in R. I just compiled a 2000-line file with code from my latest project, but none of the functions would run faster. Apparently I need to break down things a little more and use more subfunctions.

Well, so I tried a much easier example. I took runiregGibbs from the well known bayesm packages (which is a function completely written in R) and compiled it. There’s a visible change, but it’s quite small:

To leave a comment for the author, please follow the link and comment on their blog: [the] joint posterior distribution.

R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.



If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Comments are closed.

Search R-bloggers

Sponsors

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)