You can use rowSums
to construct the condition in base R:
df[rowSums(df > 10) >= 1, ]
with dplyr
(0.7.0), now you can use filter_all
like this:
library(dplyr)
filter_all(df, any_vars(. > 10))
More Related Contents:
- R subset based on range of dates [closed]
- Select rows from a data frame based on values in a vector
- How to subset matrix to one column, maintain matrix data type, maintain row/column names?
- Opposite of %in%: exclude rows with values specified in a vector
- How to drop columns by name in a data frame
- Subset / filter rows in a data frame based on a condition in a column
- How to replace NA with mean by group / subset?
- How do I extract a single column from a data.frame as a data.frame?
- Subset dataframe by multiple logical conditions of rows to remove
- Subset data frame based on multiple conditions [duplicate]
- Subset a dataframe between 2 dates
- Subset data to contain only columns whose names match a condition
- Subset and ggplot2
- Extract matrix column values by matrix column name
- Reading multiple files and calculating mean based on user input
- Collapse rows with overlapping ranges
- How to subset data in R without losing NA rows?
- Using grep to help subset a data frame
- Subset based on variable column name
- from data table, randomly select one row per group
- Return data subset time frames within another timeframes?
- Subsetting a dataframe for a specified month and year
- Looping through t.tests for data frame subsets in r
- Delete duplicate rows in two columns simultaneously [duplicate]
- Filter data frame rows based on values in vector
- R: How to filter/subset a sequence of dates
- Undefined columns selected when subsetting data frame
- Subset data.table by logical column
- How to get all possible subsets of a character vector in R?
- Filtering rows in R unexpectedly removes NAs when using subset or dplyr::filter