-
-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Inconsistent names handling with arithmetic operators on xts objects #114
Comments
This is because x <- .xts(1:3,1:3,dimnames=list(NULL, c("-1")))
x + x[-1,]
# X.1
# 1969-12-31 18:00:02 4
# 1969-12-31 18:00:03 6
z <- as.zoo(x)
z + z[-1,]
# -1
# 1969-12-31 18:00:02 4
# 1969-12-31 18:00:03 6 In order to fix this, support for |
I think I can fix that if you would like me to. |
You're more than welcome to try, but I have to warn you: I'm going to be extremely critical of any patch(s) that attempt to change I don't say that to discourage you from attempting, but so that you don't get discouraged when I push back. So, to reiterate, please do try, but be ready for lots of questions and critiques. |
Thanks for the heads up, fair point. I'll see what I can do. If this is more difficult than I think, well, at least I opened an issue :) |
I just have found this same inconsistency in another form:
It's also a somewhat weird the opposite merge get a different index in the result:
|
@fcasarramona That's not really another form. It's what I said in my initial comment: The different index value in your second example is expected. |
Related to #293 |
Not a bug per se, but an inconsistency in names handling which caught me by surprise. Here's all right:
If there's an mismatch in dates, the coredata is fine, but the names get reprocessed:
I suspect a new xts object is being created, and some along that way conversion wrecks names.
The text was updated successfully, but these errors were encountered: