R> if (done=TRUE) tweet me!

December 11, 2009

(This article was first published on Stats raving mad » R, and kindly contributed to R-bloggers)

Let’s say that you’re fitting a cumbersome model so time is not to waste over a PC staring at the screen half anxious-half bored…

Then, you can always leave and go on with meetings and all your daily routine and have R notify you the results! How?

We will illustrate the situation above using some Bayesian Model Averaging code adapted by Martin Feldkircher & Stefan Zeugner. You should download the code and source everything in R except for the example in the end (after the definition of the functions!).

#The code to get a model

K=ncol(dataM)-1  # nr. of regressors

# this setting corresponds to a uniform prior on the model space (prior.msize=K/2 and theta="fix")
# and the ric specification since K^2> N (with N the nr. of observations) as suggested by fls

This is gonna take s o m e time (really!), so you could let R working and go out for a cup of coffee (typical of Greek people!). Add the following at the end of the above code.

sess <- initSession('myUser', 'myPass') # Set your user account info
ns <- updateStatus('A model waits for you @ home ;) ', sess)

Would you really care enough to check whether the fit is done when outside?

To leave a comment for the author, please follow the link and comment on their blog: Stats raving mad » R.

R-bloggers.com offers daily e-mail updates about R news and tutorials on topics such as: Data science, Big Data, R jobs, visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...

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

Tags: , , , , , ,

Comments are closed.


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)