Posts Tagged ‘ zoo ’

R: calculations involving months

July 7, 2011
By
R: calculations involving months

Ask anyone how much time has elapsed since September last year and they’ll probably start counting on their fingers: “October, November…” and tell you “just over 9 months.” So, when faced as I was today with a data frame (named dates) like this: How to add a 7th column, with the number of months between

Read more »

Fixed: Unable to plot a decent x-Axis in a time series plot using zoo

June 16, 2011
By

Here is the link to the original problem. Briefly, I was unable to plot a custom x-axis showing abbreviated months in a time series plot of a zoo object. In the plot.zoo() function set xaxt = "n" to suppress plotting … Continue reading →

Read more »

Loading CSV with Date and Time into Zoo in R

March 25, 2011
By

Sometimes you are facing time series which has both date and time property in one column in CSV file. In this case you need to pass additional parameter into read.zoo function:   View Code RSPLUS1 z <- read.zoo("/path/to/file/test.csv&...

Read more »

White Bumblebee Implemented in R

December 18, 2010
By
White Bumblebee Implemented in R

White Bumblebee is a trade system based on a simple moving average crossover, but with a special twist. Imagine your thermostat triggering your furnace to shut off or turn on every time a temperature crossed a threshold. If the thermostat didn't have a...

Read more »

White Bull, An Algorithm in R

December 11, 2010
By
White Bull, An Algorithm in R

Algorithms are curious creatures. They behave in a very predictable way. They do as they are told and do it the same way every time. What they lack in imagination, they make up in reliability. You cannot talk an algorithm into saying something it's not...

Read more »