mages / googleVis

Interface between R and the Google Chart Tools
https://mages.github.io/googleVis/
358 stars 156 forks source link

gvisTable not plotting larger DFs? #96

Closed bonyadn closed 2 years ago

bonyadn commented 3 years ago

I have a large DF that is plotted properly if I use a small sample but not if make it too big.

plot(gvisTable(sample_n(dateframe,50))) -> showing table in browser plot(gvisTable(sample_n(dateframe,2000))) -> not showing table in browser

Is this something I can fix or is it just not possible with gvisTable()?

The table looks like this:

ID headline num domain url date
1 some random text 4 google.com https://www.google.com/.... 2016-09-19
3 sandommm text 2 4 nt.com https://www.nt.com/... 2020-10-20
2 sandom text 6 facebook.com https://www.facebook.com/... 2020-12-31

with over 1k entries

mages commented 3 years ago

The following works for me

library(googleVis)
plot(gvisTable(data.frame(x=1:2000, y=sample(2000))))
bonyadn commented 3 years ago

The following works for me

library(googleVis)
plot(gvisTable(data.frame(x=1:2000, y=sample(2000))))

I'm sorry, I should have specified it a bit more. I have a large df looking like this:

ID headline num domain url date
1 some random text 4 google.com https://www.google.com/.... 2016-09-19
3 sandommm text 2 4 nt.com https://www.nt.com/... 2020-10-20
2 sandom text 6 facebook.com https://www.facebook.com/... 2020-12-31
mages commented 3 years ago

Can you please provide a minimal reproducible example?

bonyadn commented 3 years ago

Can you please provide a minimal reproducible example?

I'll try to. Do you know a fast method to remove sinsitive data?

mages commented 3 years ago

I suggest you create artificial data like I did. However, most likely your data is causing the problem. Try to identify with your data from which row onwards the error starts to occur. See if it works when you exclude that row.

bonyadn commented 3 years ago

I suggest you create artificial data like I did. However, most likely your data is causing the problem. Try to identify with your data from which row onwards the error starts to occur. See if it works when you exclude that row.

I built it with Artificial Data and it worked fine, seems like there is a problem with my DF, thank you for your time and help