Check if a value or a logical expression is TRUE in R Programming - isTRUE() Function Last Updated : 16 Jun, 2020 Summarize Comments Improve Suggest changes Share Like Article Like Report isTRUE() function in R Language is used to check whether a value or a logical expression is true or not. Syntax: isTRUE(x) Parameters: x: logical or number-like vector Example 1: Python3 1== # R Program to test whether # an expression is TRUE # Calling isTRUE() Function isTRUE(1) isTRUE(1>0) isTRUE("a") Output: [1] FALSE [1] TRUE [1] FALSE Example 2: Python3 1== # R Program to test whether # an expression is TRUE # Creating vectors x <- c(1, 2) y <- c(4, 5, 6, 7) # Calling isTRUE() Function isTRUE(x < y) isTRUE(x && y) isTRUE(x || y) Output: [1] FALSE [1] TRUE [1] TRUE Comment More infoAdvertise with us Next Article Check if an Object is an Expression in R Programming - is.expression() Function N nidhi_biet Follow Improve Article Tags : R Language R Math-Function R Vector-Function Similar Reads Check if an Object is an Expression in R Programming - is.expression() Function is.expression() function in R Language is used to check if the object passed to it as argument is of the expression class. Syntax: is.expression(object) Parameters: object: Object to be checked Example 1: Python3 1== # R program to check if # an object is an expression # Creating an object x <- 1 min read Check if an Object is a Table in R Programming - is.table() Function is.table() function in R Language is used to check if an object is a table. Syntax: is.table(x) Parameters: x: Object to be checked Example 1: Python3 1== # R Program to check # if an object is a table # Creating a vector vec = c(2, 4, 3, 1, 2, 3, 2, 1, 4, 2) # calling is.table() Function is.table(v 1 min read Check whether a value is logical or not in R Programming - is.logical() Function is.logical() function in R Language is used to check whether a value is logical or not. Syntax: is.logical(x) Parameters: x: Value to be checked Example 1: Python3 1== # R Program to test whether # a value is logical or not # Calling is.logical() function is.logical(0) is.logical(!5) is.logical(T) i 1 min read Check if the Object is a List in R Programming - is.list() Function is.list() function in R Language is used to return TRUE if the specified data is in the form of list, else returns FALSE. Syntax: is.list(X) Parameters: x: different types of data storage Example 1: Python3 # R program to illustrate # is.list function # Initializing some list a <- list(1, 2, 3) b 1 min read Check if an Object is sorted or not in R Programming - is.unsorted() Function is.unsorted() function in R Language is used to check if an object is sorted or not. It returns False if the object is sorted otherwise True. Syntax: is.unsorted(x) Parameters: x: Object Example 1: Python3 1== # R Program to check if # an object is sorted # Creating a vector x <- c(1:9) # Creatin 1 min read Check if values in a vector are True or not in R Programming - all() and any() Function In this article, we are going to check if the values in a vector are true or not in R Programming Language. R - all() function all() function in R Language will check in a vector whether all the values are true or not. Syntax: all(x, na.rm)Â Parameters:Â x: vectorna.rm: logical, if NA value to remov 2 min read Like