February 2014

Interactive exploration of a prior’s impact

February 21, 2014 | FelixS

The probably most frequent criticism of Bayesian statistics sounds something like “It’s all subjective – with the ‘right’ prior, you can get any result you want.”. In order to approach this criticism it has been suggested to do a sensitivity analysis (or robustness analysis), that demonstrates how the choice of ... [Read more...]

Forecasting within limits

February 21, 2014 | Rob J Hyndman

It is common to want forecasts to be positive, or to require them to be within some specified range . Both of these situations are relatively easy to handle using transformations. Positive forecasts To impose a positivity constraint, simply work on the log scale. With the forecast package in R, this ... [Read more...]

Self-written function help

February 21, 2014 | Deciphering life: One bit at a time :: R

Self-written function help I have noted at least one instance (and there are probably others) about how Python's docStrings are so great, and wouldn't it be nice to have a similar system in R. Especially when you can have your new function tab completion available depending on your development environment. ... [Read more...]

Most Entertaining NBA Teams

February 20, 2014 | jlebeau

In a previous post I highlighted the Thunder keeping more of their games closer (within 3 points) than anyone else in the NBA.  As the season has progressed, this has changed.  The Thunder are still in the top five of most close games as of 2... [Read more...]

The gap between data mining and predictive models

February 20, 2014 | John Mount

The Facebook data science blog shared some fun data explorations this Valentine’s Day in Carlos Greg Diuk’s “The Formation of Love”. They are rightly receiving positive interest in and positive reviews of their work (for example Robinson Meyer’s Atlantic article). The finding is also a great opportunity ... [Read more...]

Control R from Excel

February 20, 2014 | Emmanuel Jjunju

Here is a simple script modified from univie.ac.at that you can just run in R. Follow the instructions in the ensuing dilaogue boxes after running the script. This RExcel interface will help you if you tend to work with people whose knowledge of R is ... [Read more...]

Merge by City and State in R

February 20, 2014 | Mollie

Often, you'll need to merge two data frames based on multiple variables. For this example, we'll use the common case of needing to merge by city and state.First, you need to read in both your data sets:# import city coordinate data:coords [Read more...]

Data Analysis for Genomics MOOC

February 20, 2014 | Stephen Turner

Last month I told you about Coursera's specializations in data science, systems biology, and computing. Today I was reading Jeff Leek's blog post defending p-values and found a link to HarvardX's Data Analysis for Genomics course, taught by Rafael Iriz... [Read more...]

RcppArmadillo 0.4.000.4

February 20, 2014 | Thinking inside the box

A new minor release of RcppArmadillo is now on CRAN and in Debian. RcppArmadillo brings the Armadillo templated C++ library for linear algebra to R by means of Rcpp. This release contains both a few minor bugfixes from the 4.000 branch of Armadillo and some enhancements in RcppArmadillo itself that are ... [Read more...]

No need for SPSS – beautiful output in R #rstats

February 20, 2014 | Daniel

About one year ago, I seriously started migrating from SPSS to R. Though I’m still using SPSS (because I have to in some situations), I’m quite comfortable and happy with R now and learnt a lot in the past months. But since SPSS is still very wide spread ... [Read more...]

dvn – Sharing Reproducible Research from R

February 20, 2014 | rOpenSci Blog - R

Reproducible research involves the careful, annotated preservation of data, analysis code, and associated files, such that statistical procedures, output, and published results can be directly and fully replicated. As the push for reproducible research has grown, the R community has responded with an increasingly large set of tools for engaging ... [Read more...]

Function to Simplify Loading and Installing Packages

February 20, 2014 | Jason Bryer

One of the more tedious parts of working with R is maintaining my R library. To make my R scripts reproducible and sharable, I will install packages if they are not available. For example, the top of my R scripts tend to look something like this:
if(!require(devtools) | !require(ggplot2) | !require(psych) | !require(lme4) | !require(benchmark)) {
	install.packages(c('devtools','ggplot2','psych','lme4','benchmark'))
}
This has worked ... [Read more...]

R in Insurance 2014 Conference Poster

February 20, 2014 | Markus Gesmann

Here is the poster for the 2nd R in Insurance conference on Monday 14 July 2014 at Cass Business School in London:R in Insurance 2014 conference poster. Download PDF versionImportant dead lines to keep in mind:Abstract submissions: 28 March 2014Early b... [Read more...]

Backcasting in R

February 19, 2014 | Rob J Hyndman

Sometimes it is useful to “backcast” a time series — that is, forecast in reverse time. Although there are no in-built R functions to do this, it is very easy to implement. Suppose x is our time series and we want to backcast for periods. Here is some code that should ... [Read more...]

Identification of ARMA processes

February 19, 2014 | arthur charpentier

Last week (in the MAT8181 course) in order to identify the orders of an ARMA process, we’ve seen the eacf method, and I mentioned the scan method, introduced in Tsay and Tiao (1985). The code below – to produce the output of the scan procedure – has been adapted from an old ... [Read more...]

Extract information from texts with regular expressions in R

February 19, 2014 | Kun Ren

People love dealing with well-structured data. It costs much less efforts than working with disorganized raw texts. In economic and financial research, we typically download data from open-access websites or authentication-required databases. These sources may provide data in multiple formats. For example, almost all databases are able to provide data ... [Read more...]
1 2 3 4 5 6 14

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)