Column filter option when viewing large datasets

Hello community,

A few colleagues have a feature available on their IDEs which isn't available to a number of other people, including myself, and we're all quite jealous (we're have 1.2.1335 Rstudio server). When viewing large datasets (100's of cols), there seems to be a feature that is only loading/displaying a subset of the columns. The impact is that you can quickly View() and move around the dataset rapidly.. He's a screenshot of the "Cols:" filter in action... Can anyone help me figure out how to enable this?? tia!

Hi, and welcome

I haven't seen this feature as part of RStudio, but it's easy to do from the Console with the dplyr package

To create a subset of columns

frac_vars <- c("F_808.0", "F_808.1", "F_808.2", "F_808.3", "F_808.4", "F_808.41", "F_808.42", "F_808.43", "F_808.49", "F_808.5", "F_808.51", "F_808.52", "F_808.53", "F_808.59", "F_808.8", "F_808.9")
fractures <- all_int %>% dplyr::select(frac_vars)

To move those columns to the front

fractures <-  all_int %>% dplyr::select(frac_vars, everything())

thanks for the reply, but this feature/question isn't about reording columns or otherwise filtering data. Large column datasets taking a long time for View() has been discussed here, here, etc...

What I'm asking is how to enable that Cols: feature in the UI which significantly mitigates the pain of working with very wide data.

The [current status] (https://github.com/rstudio/rstudio/pull/3878) may be of use. I was suggesting a work-around for dealing with "only loading/displaying a subset of the columns."

Ah ha! Definitely on the right track, this is indeed the feature, and it looks like it's been merged into the release, but just need to figure out why it's not enabled for some of us. Was a toggle ever implemented? If so, I see nothing in Global options.

To make things concrete, this command:

View(wide_test <- data.frame(matrix("blah", ncol = 1000, nrow = 1000)))

Takes about ~20 seconds to load the "blah" dataset, whereas my colleague, it displays it in less than a second with that "Cols: << < 1 - 50 > >>" render functionality.

Argh.

Got it! I've forwarded this to someone who has deeper insight to the UI than I do.

I might be stealing JCBlum's thunder, but she suggests it's very odd that folks there would be seeing different interfaces if they truly are all on the same RStudio Server running 1.2.1335.

Could you ask them to confirm the RStudio version info from machines that do and do not see the feature? (run RStudio.Version() at the console).

Also note that the data Viewer will only max out and give this UI option when there are more than 50 columns/variables in the table.

2 Likes

Thanks for the continued help, all.

Server where feature is missing:

> RStudio.Version()
$citation

To cite RStudio in publications use:

  RStudio Team (2018). RStudio: Integrated Development for R. RStudio, Inc., Boston, MA URL http://www.rstudio.com/.

A BibTeX entry for LaTeX users is

  @Manual{,
    title = {RStudio: Integrated Development Environment for R},
    author = {{RStudio Team}},
    organization = {RStudio, Inc.},
    address = {Boston, MA},
    year = {2018},
    url = {http://www.rstudio.com/},
  }


$mode
[1] "server"

$version
[1] ‘1.2.1335’

Colleague who has the feature present:

> RStudio.Version()
$citation

To cite RStudio in publications use:

  RStudio Team (2018). RStudio: Integrated Development for R. RStudio, Inc., Boston, MA URL http://www.rstudio.com/.

A BibTeX entry for LaTeX users is

  @Manual{,
    title = {RStudio: Integrated Development Environment for R},
    author = {{RStudio Team}},
    organization = {RStudio, Inc.},
    address = {Boston, MA},
    year = {2018},
    url = {http://www.rstudio.com/},
  }


$mode
[1] "server"

$version
[1] ‘1.2.1335’

I happen to have a mac desktop where the feature is present:

> RStudio.Version()
$citation

To cite RStudio in publications use:

  RStudio Team (2018). RStudio: Integrated Development for R. RStudio, Inc., Boston, MA URL
  http://www.rstudio.com/.

A BibTeX entry for LaTeX users is

  @Manual{,
    title = {RStudio: Integrated Development Environment for R},
    author = {{RStudio Team}},
    organization = {RStudio, Inc.},
    address = {Boston, MA},
    year = {2018},
    url = {http://www.rstudio.com/},
  }


$mode
[1] "desktop"

$version
[1] ‘1.2.1335’

Now, if that data is created above (View(wide_test <- data.frame(matrix("blah", ncol = 1000, nrow = 1000)))

Here's a screenshot from my mac of the feature Present

cont...

And here's a screenshot from my server instance where it's Absent

And I'll add that it takes ~30 second for the View() to populate, and it's even worse if you scroll. On an Rstudio where the feature is present, it loads instantly and you can zoom around.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.