About 6,410,000 results
Open links in new tab
  1. r - Summarizing multiple columns with dplyr? - Stack Overflow

    I'm struggling a bit with the dplyr-syntax. I have a data frame with different variables and one grouping variable. Now I want to calculate the mean for each column within each group, using …

  2. r - dplyr summarise_each with na.rm - Stack Overflow

    Sep 10, 2014 · Is there a way to instruct dplyr to use summarise_each with na.rm=TRUE? I would like to take the mean of variables with summarise_each("mean") but I don't know how to …

  3. Relative frequencies / proportions with dplyr - Stack Overflow

    11 For the sake of completeness of this popular question, since version 1.0.0 of dplyr, parameter .groups controls the grouping structure of the summarise function after group_by summarise …

  4. r - Count number of rows by group using dplyr - Stack Overflow

    I am using the mtcars dataset. I want to find the number of records for a particular combination of data. Something very similar to the count(*) group by clause in SQL. ddply() from plyr is …

  5. r - Understanding the purpose of .groups = "drop" in dplyr's …

    May 3, 2024 · I'm having trouble grasping the purpose of .group = "drop" in dplyr's summarise function. I'm attempting to execute the following code to display the top 20 stations along with …

  6. r - Sum across multiple columns with dplyr - Stack Overflow

    Mar 5, 2015 · 183 My question involves summing up values across multiple columns of a data frame and creating a new column corresponding to this summation using dplyr. The data …

  7. Aggregate / summarize multiple variables per group (e.g. sum, …

    A few final notes: By default, summarise() drops the last level of grouping, so all the examples above would still be grouped by year. To drop all grouping, you can add an ungroup() call, or …

  8. r - summarizing counts of a factor with dplyr - Stack Overflow

    Sep 12, 2014 · I want to group a data frame by a column (owner) and output a new data frame that has counts of each type of a factor at each observation. The real data frame is fairly large, …

  9. r - How to sum a variable by group - Stack Overflow

    Here are some more examples of how to summarise data by group using dplyr functions using the built-in dataset mtcars: # several summary columns with arbitrary names

  10. r - dplyr - summary table for multiple variables - Stack Overflow

    Jan 4, 2016 · How to create simple summary statistics using dplyr from multiple variables? Using the summarise_each function seems to be the way to go, however, when applying multiple …