10 data filtering tips using R programming. Use the tidyverse to filter and subset your data.

แชร์
ฝัง
  • เผยแพร่เมื่อ 3 ธ.ค. 2024

ความคิดเห็น • 105

  • @RProgramming101
    @RProgramming101  ปีที่แล้ว

    Get my FREE cheat sheets for R programming and statistics (including transcripts of these lessons) here: www.learnmore365.com/pages/membership-r-programming-data-visualization-and-research-methods

  • @lindasturm-flores6752
    @lindasturm-flores6752 3 ปีที่แล้ว +31

    I was about to give up on learning R when I came across your videos. I'm finally making progress! Thanks so much.

  • @muwongejosephjunior6131
    @muwongejosephjunior6131 4 ปีที่แล้ว +31

    "Boom shaka laka!"
    Thank you Greg, we appreciate these videos!

  • @deltax7159
    @deltax7159 2 ปีที่แล้ว +2

    there are tons of really smart people out there that can't teach, this man really knows how to teach, he understands learning.

    • @RProgramming101
      @RProgramming101  2 ปีที่แล้ว

      So nice of you - thanks for the great feedback!

  • @kirklands12345
    @kirklands12345 2 ปีที่แล้ว +1

    Thank you so much! There's a ton of videos on how to remove NAs and change NAs. This was the first video that shows how to create a dataset with only NAs! Thank you

    • @RProgramming101
      @RProgramming101  2 ปีที่แล้ว +1

      You're welcome! Thank you for the feedback, Brianne 👍👍

  • @eddieramosgarcia9057
    @eddieramosgarcia9057 2 ปีที่แล้ว +5

    I'm following a course in Linkedin about mastering "R", however, I'm mastering it with your content instead, thanks so much !!!

  • @Wissro
    @Wissro 2 ปีที่แล้ว +1

    Great to see you're still making videos, they are extremely helpful for getting to know R

    • @RProgramming101
      @RProgramming101  2 ปีที่แล้ว

      Glad you like them! Glad it was helpful! Thank you :)

  • @samyuktharajkumaran8363
    @samyuktharajkumaran8363 ปีที่แล้ว +1

    You're an outstanding teacher and sparked my interest in delving deeper into R. Profound regards.

    • @RProgramming101
      @RProgramming101  ปีที่แล้ว

      Thanks for the feedback. Much appreciated!

  • @noahsalazar2738
    @noahsalazar2738 2 ปีที่แล้ว

    Please keep the videos coming my friend. You are providing an invaluable service, and the quality of these videos are top notch!

  • @bukolaadebayo1891
    @bukolaadebayo1891 2 ปีที่แล้ว

    Thank you so much!!!!! You just made my day with the "filter and between".

  • @ellieanderson767
    @ellieanderson767 4 ปีที่แล้ว +7

    Greg, I've watched all your videos and they're so helpful! Would you be willing to create some videos highlighting different types of data visualization?

  • @jordantriesto3398
    @jordantriesto3398 2 ปีที่แล้ว

    I am trying to work on a case study and this saved me so many hours of confusion and frustration. The filter part where are you added the == | sign was so helpful

  • @getachewaga7734
    @getachewaga7734 3 ปีที่แล้ว

    I found your videos very important as a beginner in using R. Thank you.

  •  3 ปีที่แล้ว +1

    I didn't know about between() and near(). This is really helpful. Thank you very much!

  • @sofiaferreira7356
    @sofiaferreira7356 4 ปีที่แล้ว +1

    Very informative and concise video! Please keep doing more!!

  • @vanishreehegde5629
    @vanishreehegde5629 4 ปีที่แล้ว +2

    Excellent !! Making it so easy to learn R. Thank you. Looking forward to more videos.

    • @RProgramming101
      @RProgramming101  4 ปีที่แล้ว +1

      Thanks for the comment 😀. More videos to come.

  • @ailabraiges9930
    @ailabraiges9930 4 ปีที่แล้ว

    you not only teach in a way very easy way to learn for anyone but you also make it fun so I want to learn more and more! Thank-you very much sir, God bless.

  • @rogerwilkins9701
    @rogerwilkins9701 4 ปีที่แล้ว +1

    Amazing videos! Please don't stop doing these! they're so useful and well done

  • @rjluciano
    @rjluciano 4 ปีที่แล้ว +2

    Information is presented with clarity and video is well produced.

  • @belembaogo007
    @belembaogo007 3 ปีที่แล้ว +1

    Do more man, these videos are really good

  • @deeplysuperficial8132
    @deeplysuperficial8132 3 ปีที่แล้ว +1

    Love the way you edit.

  • @qbwoa
    @qbwoa 4 ปีที่แล้ว +1

    You're awesome been a teacher! Thank you.

  • @vincebutzner8181
    @vincebutzner8181 2 ปีที่แล้ว +2

    Sometimes when I get really stuck I wish I could just share my screen and ask you 100 questions, like right now for instance haha anyways thanks for videos they have been tremendously helpful!

  • @afonsoosorio2099
    @afonsoosorio2099 ปีที่แล้ว

    Great tutorial as always. Amazing filtering skills to command for any aspiring data analyst

  • @lol-cf7ec
    @lol-cf7ec 3 ปีที่แล้ว +1

    I recently started university and these videos are really really helpful!! Thank you☺️

  • @mahmudurrahman9052
    @mahmudurrahman9052 4 ปีที่แล้ว

    Well explained, easy to understand . Thanks for you great effort!

  • @katherinewu4204
    @katherinewu4204 3 ปีที่แล้ว

    Wow! Thank you so much. This has really helped me in my undergraduate studies :) I really appreciate it!!!

  • @killerkamatis2243
    @killerkamatis2243 4 ปีที่แล้ว

    Thank you so much! More video Please.
    Bless you.

  • @AlexisMelo
    @AlexisMelo 3 ปีที่แล้ว

    You are amazing! 👏🏻👏🏻👏🏻👏🏻 Thanks for that. New subscriber here.

  • @SemestaPsikometrika
    @SemestaPsikometrika 4 ปีที่แล้ว

    Really good channel, can't wait to see your next video. Thank you for sharing

  • @heartheart5543
    @heartheart5543 4 ปีที่แล้ว

    thank you so much, so clear and informative

  • @steves511
    @steves511 4 ปีที่แล้ว +3

    Gosh you are good at explaining this, thanks a bunch. Can you tell me what theme you use for Rstudio, really digging it!

    • @jcronin1230
      @jcronin1230 3 ปีที่แล้ว

      Looks like "Chaos" to me

  • @edgarsmeets7519
    @edgarsmeets7519 ปีที่แล้ว

    It worked well for me, except one thing: after the exclamation mark, a space should be entered. Nice video's, Greg!

  • @folashadeolaitan6222
    @folashadeolaitan6222 ปีที่แล้ว

    Boom shakalaka!! 🤣🤣🤣🤣New here and loving your contents

  • @snehabharadwaj6375
    @snehabharadwaj6375 ปีที่แล้ว

    5 min studying R used to blow off my mind, but now i actually enjoy R

  • @vrajtalati5300
    @vrajtalati5300 ปีที่แล้ว

    Can you please make a video on joints and how to perform them in R because your explanation is outstanding, I must say! Please make a video on combining two tables with left join.

  • @space5more
    @space5more 8 หลายเดือนก่อน

    Very nice. Thanks -

  • @beaalvarez429
    @beaalvarez429 3 ปีที่แล้ว

    Very useful, thanks!

  • @raphaelortiz4459
    @raphaelortiz4459 3 ปีที่แล้ว

    Great video!! What theme are you using in R studio?? Colors are very nice

  • @alexandrosagloumis3487
    @alexandrosagloumis3487 4 ปีที่แล้ว +1

    Good job my friend!!!

  • @devilalsethi4615
    @devilalsethi4615 2 ปีที่แล้ว

    Superb video sir. Thank you so much
    But I'm stuck at how we can apply loop in filter function so that it can filter one thing and make a file and then filter next and make next file and so on. Please give solution sir!!!

  • @aryaman3039
    @aryaman3039 3 ปีที่แล้ว

    Love this video! thanks

  • @hayleyreyno7181
    @hayleyreyno7181 4 ปีที่แล้ว

    Thanks so much for such a helpful video! Would you mind making a video on how to make different types of plots in R?

  • @maheshgurumoorthi4391
    @maheshgurumoorthi4391 3 ปีที่แล้ว

    Thanks for the video, we can also use multiple filter clause
    my_data %
    select (name, sleep_total) %>%
    filter (name %in% c("Cow", "Dog", "Horse") |
    between(sleep_total, 16,18))

  • @toyl6727
    @toyl6727 3 ปีที่แล้ว

    Brilliant. You should have a faculty position at a University.

  • @lorenzoconti7372
    @lorenzoconti7372 2 ปีที่แล้ว

    Bro you're saving lifes

  • @BobBeatski71
    @BobBeatski71 2 ปีที่แล้ว

    Wow, the NEAR function is very interesting. I was wondering how I could have R 'scan' a huge set of standard deviation values and determine those whos mean & medians stray out of a tolerance. 👍

  • @chalmerditmars7037
    @chalmerditmars7037 2 ปีที่แล้ว

    I love your videos, for some reason "my_data

  • @rjluciano
    @rjluciano 4 ปีที่แล้ว +1

    I am interested in learning how to weight data in R. Greg Martin, is there any chance you will cover data weighting in the future? (By the way I abbreviated my TH-cam name to the first letter of my first name, Rob. That was unconnected to the fact I have taken an interest in learning R programming)

    • @RProgramming101
      @RProgramming101  4 ปีที่แล้ว +2

      Thanks for the comment Rob. Yes, I’ll create a video on data weighting for sure. Thanks for the suggestion.

  • @legojenn
    @legojenn 3 ปีที่แล้ว

    I just discovered your channel and I'm finding it not nearly as impossible to get myhead around R using Tidyverse. A challenge that I am having is filtering a dataset on year. I want to keep the last ten years of data. I don't have the vocabulary to dynamically filter. Ideally, if a new year is added to my dataset, then the last year will be dropped and the new year will be added to the analyses. Do you have any suggestions on how to filter when the values in the year column is unknown but I want the most recent ten?

  • @CanDoSo_org
    @CanDoSo_org ปีที่แล้ว

    Hi, Greg. About your coding style, are the white spaces between arguments and symbols created automatically or you set style after coding? Many thanks.

  • @frankjr3787
    @frankjr3787 2 ปีที่แล้ว

    Amazing content for learning R, thank you so much. Just a qq - is there an example of using a filter function with starts_with, ends_with, contains functions? Similar to how those functions are combined with the select function?

    • @StefanoVerugi
      @StefanoVerugi 2 ปีที่แล้ว +1

      using stringr library, filter(df, str_detect(species, "^D")) , where ^D means starts with D
      credits to @weecology

    • @afonsoosorio2099
      @afonsoosorio2099 ปีที่แล้ว

      Good one. I am sure it there, filtering based on wildcard

  • @amam3146
    @amam3146 8 วันที่ผ่านมา

    Hi Greg! Amazing video! By the way my dataset appeared to change in the console section but when I clicked on it, it was still the same(after trying to filter or mutate something). Can you tell me whats wrong with that?

    • @RProgramming101
      @RProgramming101  8 วันที่ผ่านมา

      hi there - thanks for the feedback. If you want the actual dataset to change (and not just the output in the console) you need to overwrite the data object. So my_data % filter(variable, ...)

    • @amam3146
      @amam3146 7 วันที่ผ่านมา

      @@RProgramming101 Thanks alot!!! 😘problem solved

  • @devilalsethi4615
    @devilalsethi4615 2 ปีที่แล้ว

    sir how can we filter the values of coordinate pairs in loop.

  • @frankjr3787
    @frankjr3787 2 ปีที่แล้ว

    In this example, if I wanted to filter for all observations with a name 'containing' the letters "ow" , how would that be possible?

  • @marcoventura9451
    @marcoventura9451 3 ปีที่แล้ว

    Very good video. I have noticed that you can't use a variable in filter () that is not included in the select() part. For example:
    mydata%
    select(name, order, bodywt, sleep_total) %>%
    filter(is.na(conservation))
    gives an error
    Errore: Problem with `filter()` input `..1`.
    x oggetto "conservation" non trovato
    i Input `..1` is `is.na(conservation)`.
    In sql you can filter for a variable even if itìs not included in the select clasue. It's strange.

    • @RProgramming101
      @RProgramming101  3 ปีที่แล้ว +3

      Thanks for the comment Marco - what you can do is filter before the select (if you want to). Once you've used the select function in R, the dataset that you're using is changed and narrowed to only include those variables that you have selected.

  • @wyclifeoluoch9376
    @wyclifeoluoch9376 4 ปีที่แล้ว +1

    Good job Greg,
    Am surprised when you used:
    filter(name %in% c("Cow", "Dog", "Horse")
    The output:
    Cow
    Dog
    Goat
    How did "Horse" change to "Goat" ?

    • @RProgramming101
      @RProgramming101  4 ปีที่แล้ว +1

      Ooooih!!! Well spotted!!! It was a post production editing mistake. I didn’t see it until now (blush)

  • @OnizukaAllMighty
    @OnizukaAllMighty 2 ปีที่แล้ว

    how to get the "or" symbol ?
    thank you

  • @setarehsohail5422
    @setarehsohail5422 2 ปีที่แล้ว

    Thank….I have a question…How can I change the coulers of some sign like () or%>% like yours? Where is the setting the window of R?

    • @theolanadimulam3994
      @theolanadimulam3994 2 ปีที่แล้ว +1

      With R studio open, Click on the "tools" tab and select "Global options". Then look for "Appearence" on the left hand side and click on it. Under the "Editor theme" option there is a wide range of themes to choose from. When you find one you like click on "Apply".

    • @setarehsohail5422
      @setarehsohail5422 2 ปีที่แล้ว

      Thanks Theolan, for sharing your knowledge...I did it, and now I have a beautiful window in R Studio!

  • @sudhansugrahacharya7094
    @sudhansugrahacharya7094 4 ปีที่แล้ว

    How can we export the results in for Use in presentation or the likes

  • @markviya2194
    @markviya2194 ปีที่แล้ว

    How to filter from a column only in english cos i got many texts in multiple languages

  • @aklepatzky
    @aklepatzky 2 ปีที่แล้ว

    I get this error when filtering: unexpected input in "filter(year > 1995, country %in% c(“"

  • @furaosentu
    @furaosentu 2 ปีที่แล้ว

    A Horse is a Goat!

  • @rachelkaze1347
    @rachelkaze1347 4 ปีที่แล้ว

    I don’t know why when I typed:
    my_data %
    select (name, sleep_total) %>%
    filter (name == “Cow”|
    name == “Dog”|
    name == “Goat”)
    I have to type again my_data to see the result
    Also Appear two results Cow and Goat
    Why not appears Dog’s result?

  • @gibroni94
    @gibroni94 8 หลายเดือนก่อน

    I love you

  • @elbrothersworld93
    @elbrothersworld93 3 ปีที่แล้ว

    Thank you for the video..
    Is this correct? sorry my first time doing this
    nv %

    na.omit() %>%
    group_by(vore) %>%
    summarise(av_awake = mean(awake), av_sleep_total = mean(sleep_total)) %>%
    arrange(av_awake, av_sleep_total) %>%
    select(vore, av_awake, av_sleep_total )

  • @orhanyork
    @orhanyork 4 ปีที่แล้ว +1

    Boom shaka laka :)

  • @jeslovermusic578
    @jeslovermusic578 3 ปีที่แล้ว

    Boom shakalaka😂😂😂😂😂😂

  • @tharushanonis8046
    @tharushanonis8046 4 ปีที่แล้ว

    boooom booom shaka laka

  • @Life-colours
    @Life-colours 7 หลายเดือนก่อน

    Please don't use the unfriendly sound while selecting or underlying something. It feels worst if someone has Hemdchens on.