The which() function will return the position of the elements(i.e., row number/column number/array index) in a logical vector which are TRUE. [Read more...]
The match() function returns a vector of the position of first occurrence of the vector1 in vector2. If the element of the vector1 does not exist in vector2, NA is returned. [Read more...]
Addressing the question 'R or Python for data science' depends mainly on the problems which is to be solved, the tools required to solve the problem and your personal preference. Read more.. [Read more...]
What if we need to list only the files with a specified extension using R ? Here we can make use of the functions Sys.glob() and the list.files() along with some arguments.
The library() and require() can be used to attach and load add-on packages which are already installed. The main difference between the two function is explained in the post. [Read more...]
The R working environment is called a workspace. The workspaces are stored into a directory and is reloaded the next time you open R. We can choose which directory to be used to store our projects. The common commands used for managing the workspaces are given in the blog post.
Installing RStudio in Ubuntu 12.04 and higher versions requires R to be installed. The steps given in this post will help to install R and RStudio. [Read more...]