similar to: Help with creating a ts (time series) object with daily sampling values

Displaying 20 results from an estimated 5000 matches similar to: "Help with creating a ts (time series) object with daily sampling values"

2003 Jun 06
3
irregular time-series
I make quite a lot of use of irregular time-series, and had already spent a bit of time writing an 'its' class when the 'irts' class was released via the package 'tseries'. I have experimented with the 'irts' class, and have some practical issues with its use. In some applications of irregular time-series (in my case these are financial and econometric) there are
2009 Aug 18
1
aggregating values at discreet irregular time intervals into hourly values
Hello R users, I'm a newby to R (and programming software at large) and I would need some help to sum up event data at discreet time and irregular time interval into a hourly frequency. Here is an example of my time series frame (irregular time-serie object - irts in the tseries package): time value 2008-12-19 19:11:03 GMT 1 2008-12-19 19:12:00 GMT 0 2008-12-19
2002 Feb 11
2
Time Series ts() Objects
Hi, Is it possible to create a ts() object, whose data is daily based BUT measured only on working days? In other words, suppose I have a data set with 255 observations, measured from 29 June 1959 to 30 June 1960. How would I create such a data? I tried something like: ts(c(...), start(1959, 180)) but I'm not sure what to use for frequency. In other words I don't know how to
2012 Jan 10
1
plotOHLC(alpha3): Error in plotOHLC(alpha3) : x is not a open/high/low/close time series
R version 2.12.0, 64 bit on Windows. Here is a short script that illustrates the problem: library(tseries) library(xts) setwd('C:\\cygwin\\home\\Ted\\New.Task\\NKs-01-08-12\\NKs\\tests') x = read.table("quotes_h.2.dat", header = FALSE, sep="\t", skip=0) str(x) y <- data.frame(as.POSIXlt(paste(x$V2,substr(x$V4,4,8),sep=" "),format='%Y-%m-%d
2003 Nov 20
2
ts format for daily time serie
Hi R-users: How can I format a daily time serie with ts function so the plot of the time shows the date right (dd/mm/yy) or yy.xxxx ? Excerp of the database: FECHA TRM 1 01/01/2000 1873.77 2 02/01/2000 1873.77 3 03/01/2000 1873.77 4 04/01/2000 1874.35 5 05/01/2000 1895.97 . . . 1397 10/11/2003 2843.82 1398 11/11/2003 2840.41 1399 12/11/2003 2840.41 1400 13/11/2003
2012 May 29
1
Extract time from irregular date and time data records
Hello, I am having a problem making use of some data outputted from an instrument in a somewhat weird format. The instrument outputs two columns - one called JulianDay.Hour and one called Minutes.Seconds. I would like to convert these columns into a single column with a time. So I was using substr() and paste to extract that info. This works fine for the JulianDay.Hour column as there are always
2004 Feb 23
6
Need help on parsing dates
I know this: > library(date) > x="1979-04-04" > try=as.date(x, "ymd") > print(try) [1] 4Apr79 and that `x' here has to be a string, e.g.: > x=1979-04-04 > print(x) [1] 1971 I'm stuck in reading from a file. I say: > A <- read.table(file="try") > print(A) V1 V2 1 1979-04-04
2005 Dec 29
1
R and read.irts
I thought r-help let you attach asci files but I don't think it does now so below is a sample of my data set. Thanks again. 09:40:08.5238,67.00,33 09:40:09.1968,67.00,2 09:40:09.7945,67.00,2 09:40:09.7975,67.00,2 09:40:09.8318,66.99,-3 09:40:17.6335,66.95,3 09:41:09.3393,66.95,6 09:41:11.1482,66.95,-1 09:42:07.4552,66.90,-5 09:42:12.5823,66.85,-5 09:42:14.4329,66.80,-2
2004 Jul 23
1
ts to irts
Hi R-list, I'm working with irregular time series (time series of climate data, daily data 365/6 days a year) and would like to create regular time series from them ( irts e.g. Rain <- irts(as.POSIXct(Climate[,1]),Climate[,5]) to ts e.g. test <- ts(x, start=c(1997,1), frequency=365) ) such that I can find where the gaps (lacking temperature data, ...) are and try
2004 Apr 30
1
daily time series in R
I have some daily data and would like to apply some of the time series functions to it. I have read various notes in the help archive on this, the latest I found suggested that I need to use the irts class (Irregularly spaced time series) for daily data since a year does not divide into an integer number of days. I see why I would have to do that if I have gaps (e.g. only data on weekdays) but
2005 Dec 28
1
FW: R and read.irts
I have never worked with R before so I am sorry if this is a bad question but I've tried and tried ( all day ) and I can't figure this problem out. I have the code below and I included the data file as an attachment. The code works in term of reading in the data correctly but when the graph gets created, the xaxis is really strangely/incorrectly labelled. I have been trying to understand
2004 Aug 17
1
strptime() bug? And additional problem in package "tseries"
Hi all, I've got some problems with irts objects, one of which could be a bug: 1) Read a table with several columns from Postgres and the first column is Timestamp with timezone (this is OK). An extract is: raincida$ts: [2039] "25/03/2000 22:00:00 UTC" "25/03/2000 23:00:00 UTC" [2041] "26/03/2000 00:00:00 UTC" "26/03/2000 01:00:00 UTC" [2043]
2010 Mar 24
2
translating SQL statements into data.table operations
I've recently stumbled across data.table, Matthew Dowle's package. I'm impressed by the speed of the package in handling operations with large data.frames, but am a bit overwhelmed with the syntax. I'd like to express the SQL statement below using data.table operations rather than sqldf (which was incredibly slow for a small subset of my financial data) or import/export with a
2003 Jun 19
1
Import time series data with uneven dates
I am trying to import a file of daily index closing prices in business time which excludes weekends and holidays so deltat is not constant. My file looks like the following: date close 2003.0055 47.05 2003.0082 45.71 2003.0164 43.45 2003.0192 42.96 2003.0219 44.56 2003.0247 42.99 2003.0274 42.28 2003.0356 41.74 etc. >From what I saw in the EuStockMarkets file, it appears
2012 Feb 10
2
apply pairs function to multiple columns in a data frame
I am very new to R and programming and thank you in advance for your patience and help with a complete novice! I am working with a large multivariate data set that has 10 explanatory environmental variables (e.g. temp, depth) and over 60 response variables (each is a separate species). My data frame is set up like the simplified version below: JulianDay Temperature Salinity Depth Copepod
2009 May 25
1
Working with daily data
Hello I have daily S&P 500 from 1950 for which I would like to do some time series analysis in R. Could someone please show me an example of how to create a ts/ irts object for my data? Additionally, how do I create monthly subsamples of the data. I've experimented with the window function but haven't had any luck. Thank you Ian Confidential: This electronic message and
2003 Oct 28
3
ts vs. POSIX
OK. What if I have a time series which is collected every Monday, please? What is the proper way to use the start option within the ts command in order to indicate that this is Monday data, please? Thanks again! Sincerely, Erin
2004 Jan 02
3
Importing Excel/Openoffice Dates into R
Hi, I would like to import some daily financial data from excel via csv. More specifically, I would like to be able to use the ts.union function from the tseries library as the dates are irregular and I need to line up the dates so that I can place all the variables into one data frame. The trouble is, how do I import the dates from excel into R? At the moment I'm just importing the data
2004 Aug 09
1
Easy acf and pacf for irregular time series in R
R: Is there an easy way to get the acf and pacf for an irregular times series? That is, the acf and pacf with lag lengths that are in units of time, not observation number. Thanks, Jason Higbee Research Associate Federal Reserve Bank of St. Louis The views expressed in this email are the author's and not necessarily those of the Federal Reserve Bank of St. Louis or the Federal Reserve
2004 Nov 06
1
calendar-based time-series in R
Hello, I am trying to switch to R from S-PLUS 6.1, and one problem I am having is using R for manipulation of calendar-based time-series. In S-PLUS, I commonly use the functions timeSequence(), timeDate(), and timeSeries() to align/average/aggregate data; and I also do a lot of plotting of time-series data (with calendar-based labels on the x-axis). I was wondering if anyone is familiar with