-
Notifications
You must be signed in to change notification settings - Fork 9
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
gdf() has performance issues with Date variables #89
Comments
Dunno. I looked here: https://github.com/jverzani/gWidgets2RGtk2/blob/master/R/gdf.R#L165 Nothing seems amiss, but can verify it takes some time to get there. I should check if RGtk2DataFrame has this slowdown, as it might sit there. |
I'm also getting this when using gdf() purely as a viewer, e.g.:
I also notice that the slowness seems to be related to the columns (apparently |
I did some rudimentary profiling with RStudio, and here are there results: There seem to be a lot of calls (too many?) in some parts of the code, which might suggest a loop going haywire. Though it's hard to pinpoint what precisely is going wrong as the lion's share of the time comes from an |
These are the only two places where I use |
I'm striking out. That is definitely the issue, but I can't find out how to improve it. My only suggestion is to format the dates as character before placing them into the data frame. This isn't great, but things will at least render more quickly. |
Is there perhaps some additional formatting going on for |
Sadly no. The only formatting is a call to On Thu, May 12, 2016 at 2:25 AM, landroni [email protected] wrote:
John Verzani |
Instead of formatting things per-cell, would one option be to do what we do for |
Could this be related to the general slowness of as.Date.character(), see the discussion here: http://stackoverflow.com/questions/12786335/why-is-as-date-slow-on-a-character-vector? |
Thanks for the link. I'll check. I need to work in this to get it back on On Monday, May 30, 2016, PascalVaudrevange [email protected] wrote:
John Verzani |
Hi @landroni I checked in 7086032fac355f7bfe6119a389bcdb8928b16834 to |
Thanks! Will check out over the weekend and report back. |
Performance is much better! I tried it on my real data frame, which are big and contain |
I notice that gdf() has extremely poor performance when displaying
Date
variables, even on relatively fast computers. Here's a reproducible example:Notice how it takes >10s for the CPU to calm down. But to see real slowness, try to maximize the window, scroll down, or even minimize/raise the window. All this on Linux.
What may be causing these performance issues?
The text was updated successfully, but these errors were encountered: