Top "Dplyr" questions

Use this tag for questions relating to functions from the dplyr package, such as group_by, summarize, filter, and select.

Filter rows which contain a certain string

I have to filter a data frame using as criterion those row in which is contained the string RTB. I'm …

r filter dplyr
What does %>% function mean in R?

I have seen the use of %>% (percent greater than percent) function in some packages like dplyr and rvest. What …

r syntax dplyr magrittr r-faq
How to get summary statistics by group

I'm trying to get multiple summary statistics in R/S-PLUS grouped by categorical column in one shot. I found couple …

r dplyr stat summarize s
Error: could not find function "%>%"

I'm running an example in R, going through the steps and everything is working so far except for this code …

r dplyr magrittr
Filter multiple values on a string column in dplyr

I have a data.frame with character data in one of the columns. I would like to filter multiple options …

r dplyr string-matching multiple-conditions
Can dplyr package be used for conditional mutating?

Can the mutate be used when the mutation is conditional (depending on the values of certain column values)? This example …

r if-statement dplyr case-when mutate
Summarizing multiple columns with dplyr?

I'm struggling a bit with the dplyr-syntax. I have a data frame with different variables and one grouping variable. Now …

r dplyr aggregate
dplyr mutate with conditional values

In a large dataframe ("myfile") with four columns I have to add a fifth column with values conditionally based on …

r dplyr mutate
Removing NA in dplyr pipe

I tried to remove NA's from the subset using dplyr piping. Is my answer an indication of a missed step. …

r dplyr na
Change value of variable with dplyr

I regularly need to change the values of a variable based on the values on a different variable, like this: …

r dataframe plyr dplyr