Giter Site home page Giter Site logo

Comments (4)

gdemin avatar gdemin commented on July 23, 2024

Good idea, I will definitely implement this in the next release.
If we have character started with ^ or ended with $ then we will expand it to column names. But note that we haven't parametric evaluation in this case:

# dplyr
my_vars = "Se"  
iris %>% select(starts_with(my_vars )) # work

# maditr
my_vars = "^Se"  
iris %>% dt_select(my_vars ) # will not work

from maditr.

hope-data-science avatar hope-data-science commented on July 23, 2024

While ^ and $ are good, but dplyr::contains might also be useful. Perhaps provide a new parameter like "regex"?
Thanks.

from maditr.

gdemin avatar gdemin commented on July 23, 2024

You can describe any name with "^" and "$", e. g. "^.*my_string" is equivalent to contains("my_string"). However I will think about general API for variable selectors.

from maditr.

hope-data-science avatar hope-data-science commented on July 23, 2024

I have tried too, but I could not support Sepal.Length:Petal.Length for select() so far.
See https://hope-data-science.github.io/tidydt/reference/select_dt.html.

from maditr.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.