Hi,

I have managed to convert my data frames into xts such as :

> str(z)
An ‘xts’ object from 1983-01-03 19:00:00 to 2006-01-01 22:00:00 containing:
  Data: num [1:182959, 1:2] 12.6 11.3 12.7 12.8 10.9 ...
 - attr(*, "dimnames")=List of 2
  ..$ : NULL
  ..$ : chr [1:2] "v" "DD"
  Indexed by objects of class: [POSIXt,POSIXct] TZ:
  Original class: 'data.frame'
  xts Attributes:
 NULL
I have a second set of data and would like to pull out the values of "v"
when time series from z and z1 are exact.

I have tried to look at cbind etc, but I am stuck and very confused!

Any help is appreciated

On Fri, Jul 30, 2010 at 12:44 PM, raghu [via R] <
ml-node+2307836-1452362937-369...@n4.nabble.com<ml-node%2b2307836-1452362937-369...@n4.nabble.com>
> wrote:

> Convert your datasets into xts objects and then do a cbind ordering by the
> column you want. Do a ?cbind.
>
> HTH
> Raghu
>
>  On Fri, Jul 30, 2010 at 10:33 AM, Lily_stats [via R] <[hidden 
> email]<http://user/SendEmail.jtp?type=node&node=2307836&i=0>
> > wrote:
>
>> Hi,
>>
>> I am very new to R so these questions may seem simple!
>>
>> I have a huge 2 sets of data(matrix 5x20000++) in the following formats ,
>> for example "data.txt" and "data2.txt":
>>
>> Date               Time             X           Y
>> 03/03/1983      20:00           0.1          990
>>
>> I would like to recreate a new matrix which filters through "data.txt" and
>> "data2.txt" to get something as below :
>>
>> Date             Time           X_data1              X_data2
>>  Y_data1          Y_data2
>> 31/12/2000     12:00         2.2                    5
>>  0                    990
>>
>> So I basically need :
>> 1) When Date AND Time from data1.txt and data2.txt match, list the
>> corresponding X and Y values (X_data1,X_data2,Y_data1,Y_data2)
>>
>> Thank you in advance, and I hope I have been clear enough in my message
>>
>> ------------------------------
>>  View message @
>> http://r.789695.n4.nabble.com/Data-Handling-tp2307770p2307770.html<http://r.789695.n4.nabble.com/Data-Handling-tp2307770p2307770.html?by-user=t>
>> To start a new topic under R help, email [hidden 
>> email]<http://user/SendEmail.jtp?type=node&node=2307836&i=1>
>> To unsubscribe from R help, click here.
>>
>>
>
>
> --
> 'Raghu'
>
>
> ------------------------------
> View message @
> http://r.789695.n4.nabble.com/Data-Handling-tp2307770p2307836.html
> To unsubscribe from Data Handling, click here< (link removed) >.
>
>
>

-- 
View this message in context: 
http://r.789695.n4.nabble.com/Data-Handling-tp2307770p2310318.html
Sent from the R help mailing list archive at Nabble.com.

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to