Questions tagged [dplyr]

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

Filter by
Sorted by
Tagged with
1
vote
1answer
233 views

Mutate with dynamic column names dplyr

Hi I have this dataset (It has many more columns) ...
0
votes
1answer
32 views

Remove specific words containing dots from a string

Hi I got words that contain one of the following tokens: CO. PRO. IST. How to clean my words from these tokens? Do you have any regex pattern? for example the words : ...
1
vote
1answer
778 views

Weighted mean with summarise_at dplyr

I strictly need to use the summarise_at to compute a weighted mean, with weights based on the values of another column ...
1
vote
1answer
227 views

Divide a column by itself with mutate_at dplyr

Hi I'd like to turn each non zero value of my selected columns to a 1 using mutate_at() ...
0
votes
0answers
24 views

Perform Topic Modeling By Creating a Function and Pass Along to Purrr : map() using R

My goal is to perform topic modeling (splitting into 3 topics each) by grouping words by word.trend column rather than copy and pasting block of codes for each word.trend as I have 800 unique values ...
0
votes
2answers
600 views

Mutate with custom function in R does not work

I have a data frame, containing a column called: "Frequency". Frequency has values like "Year", "Week", "Month" etc. Now I want to create a new column based on the Frequency column where Year's new ...
1
vote
2answers
306 views

Theoretical Question: Data.table vs Data.frame with Big Data

I know that I can read in a very large csv file much faster with fread using the data.table ...
1
vote
3answers
459 views

R summarise with condition

I have customer data with the products they purchased and the purchase date. I want to extract a result that shows each customer and the first two fruits they purchased. My actual set has 90000 ...
2
votes
0answers
51 views

Group_by field is not showing in the summarise output in R

In R,using dplyr package, I tried the function "summarise" and I expect the result to show along with the groupby field. However, all of a sudden I see summarized output but without the groupby filed ...