search for: ksspriggs

Displaying 5 results from an estimated 5 matches for "ksspriggs".

2008 Feb 08
2
When I cbind the POSIXct gets lost
I would like to create a new dataframe from the DateTime column of an existing dataframe and a numeric vector. When I do cbind(x[,1], y) the result is: [1,] 1199370600 12.500 [2,] 1199371200 69.375 [3,] 1199371800 23.750 where the first column you see used to look like: "2008-01-03 08:30:00 Central Standard Time" "2008-01-03 08:40:00 Central Standard Time"
2008 Jun 09
2
Plot timer in a for loop
Hello, This code works fine but is so fast I can't see anything but the last plot. for (i in nrow(X)){ plot(as.numeric(d[i,])) } I'd like to view a plot every 500 milliseconds, nrow(X) = 400. How? Thanks -- View this message in context: http://www.nabble.com/Plot-timer-in-a-for-loop-tp17741975p17741975.html Sent from the R help mailing list archive at Nabble.com.
2007 Oct 26
2
calculating correlation of a Supply/Demand measure and price change (in high frequency time series data)
Regarding "financial" data: I have a high frequency (1 minute) measure of supply/demand and I'd like to know if it has any influence on short term price changes (also 1 minute). Question: How do I calculate the correlation between this supply/demand measure and price changes (correctly)? Some facts about that data: The price changes and supply/demand measure are non-normal. An
2009 Jun 01
0
Converting data.frame to xts
I have a data.frame object and I don't really understand how to made an xts class out of it. Consider: > x <- data.frame(datetime, ltp, ltv) > head(x, 2) datetime ltp ltv 1 2009-05-05 07:30:01.604 899 1 2 2009-05-05 07:30:01.963 899 15 > class(x$datetime) [1] "POSIXt" "POSIXct" #This works for only one column and why do I lose the name
2008 Feb 27
4
Error in cor.default(x1, x2) : missing observations in cov/cor
Hello, I'm trying to do cor(x1,x2) and I get the following error: Error in cor.default(x1, x2) : missing observations in cov/cor A few things: 1. I've used cor() many times and have never encountered this error. 2. length(x1) = length(x2) 3. is.numeric(x1) = is.numeric(x2) = TRUE 4. which(is.na(x1)) = which(is.na(x2)) = integer(0) {the same goes for is.nan()} 5. I also try