Monday, January 27, 2014

Emerging Currencies with rCharts + FRED

I liked this chart a lot.

I thought I would show how we can semi-replicate it in R with rCharts.  Here it is with the currencies that are on FRED with dimplejs.

… and here with nvd3.

Code to replicate from Github Gist:

Tuesday, January 21, 2014

What Do the Odds Say? Buy Stocks Begin of Year?

At some point in 2013, I read (can’t remember where) that 2012 was a rare year for the S&P 500  where no day’s closing  price was lower than the closing price  for the first day.  So if you bought on the first day of 2012, you never had a loss for the entire year.  Well, the same thing happened 2013, so I just had to do some analysis.  Below is a dimple.js chart built using rCharts with the minimum close price for the year divided by the close price for the first day of that year.

data source: Yahoo! Finance, Standard & Poors

Thursday, January 16, 2014

Retail Relative Strength

So back before Thanksgiving I did a post Something to Think About Before Black Friday | rChart + dygraphs.  Well since then I have noticed that Retail relative strength has deteriorated considerably.  I thought it would be a good time to use good old bfast (see posts) to look for a structural breakpoint.  Below is the output.  And yes, I do plan to make interactive eventually with rCharts.

image

The remainder is what I think is very interesting.

image

Code:

Wednesday, January 15, 2014

Popularity Contest

Although I am sure most of the bloggers that discuss R on R-bloggers are not all that concerned with popularity, I thought it would be interesting to analyze (with R and rCharts, of course) the popularity of these bloggers using Feedly’s API.

 

After building the chart, I got to thinking about these two excellent posts about the nature of blog popularity.

How many more R-bloggers posts can I expect? by Markus Gesmann

Blog posts' half life - why bother? by Bruce McPherson

Clearly not posting for a month (me) is not the way to fame and glory as Google search becomes the most common referrer.

image

Also, is Bruce McPherson onto something when he points out that the nature of a blog does not lend to permanence?  Should every blog, especially educational ones, also have a different view of the same content that lends itself better to permanence?

For those that missed me, I’m back.

R code to get Feedly API data and build dimplejs chart: Github repo