Skip to content

Tag Archives: R Vector-Function

In this article, we will discuss how to Find the number of months between two dates in the R programming language.  Example: Input: Date_1 =… Read More
In mathematics, the dot product or also known as the scalar product is an algebraic operation that takes two equal-length sequences of numbers and returns… Read More
In mathematics, the cross product or also known as the vector product is a binary operation on two vectors in three-dimensional space and is denoted… Read More
split() function in R Language is used to divide a data vector into groups as defined by the factor provided. Syntax: split(x, f, drop =… Read More
paste0() and sprintf() functions in R Language can also be used to add leading zeros to each element of a vector passed to it as… Read More
rainbow() function in R Language is a built in color palettes which can be used to quickly generate color vectors of desired length taken as… Read More
sign() function in R Language is used to find the sign of the elements of the numeric vector provided as argument. It does not work… Read More
structure() function in R Language is used to get or set the structure of a vector by changing its dimensions. Syntax: structure(vec, dim) Parameters: vec:… Read More
seq.int() function in R Language is used to return a list of numbers in the specified range. Syntax: seq.int(from, to, by) Parameters: from: specified range… Read More
set.seed() function in R Language is used to create random numbers which can be reproduced. It helps in creating same random numbers each time a… Read More
na.omit() function in R Language is used to omit all unnecessary cases from data frame, matrix or vector. Syntax: na.omit(data) Parameter: data: Set of specified… Read More
seq_along() function in R Language is used to generate a sequence of the same length of the argument passed. Syntax: seq_along(x) Parameters: x: specified arguments… Read More
seq_len() function in R Language is used to generate a sequence from 1 to the specified number. Syntax: seq_len(x) Parameters: x: specified number Example 1:… Read More
rep.int() function in R Language is used to replicate a given value into a specified number of times. Syntax: rep.int(x, times) Parameters: x: specified value… Read More
pmin() function in R Language is used to return the parallel minima of the input vectors. Syntax: pmin(x1, x2) Parameters: x1: vector one x2: vector… Read More