python (65.2k questions)
javascript (44.3k questions)
reactjs (22.7k questions)
java (20.8k questions)
c# (17.4k questions)
html (16.3k questions)
r (13.7k questions)
android (13k questions)
Add rows intermittently throughout data frame
I have data like this:
df<-structure(list(username = c("dan.amy", "dan.amy", "dan.amy",
"stupidski", "stupidski", "stupidski", "cbu...

Joe Crozier
Votes: 0
Answers: 1
Simultaneously remove the first and last rows of a data frame until reaching a row that does not have an NA
I have a dataframe that contains NA values, and I want to remove some rows that have an NA (i.e., not complete cases). However, I only want to remove rows at the beginning and ending of the dataframe....

AndrewGB
Votes: 0
Answers: 7
Find the count or frequency over rolling periods by group
Here's my data:
Person<-c("Bob","Bob","Bob","Bob","Mary","Mary","Mary","Mary","Sue","Sue","S...
Tish
Votes: 0
Answers: 1
Taking the more recent row of values in R?
if i have the following dataframe:
tibble(date = c("2010_quarter_1","2010_quarter_2", "2011_end"), values = c(100,100, 2000))
How can i apply a filter condition so that ...
Beans On Toast
Votes: 0
Answers: 1