How to Compute row means

In this tutorial, we will learn how to compute means of rows with tidyverse using dplyr package. We will see multiple examples to compute row means with dplyr. Wee will start with 3. examples of computing row means using rowMeans() and dplyr’s row-wise operations on a dataframe with no missing values. And then we will… Continue reading How to Compute row means

How to replace NAs with zero in a dataframe

In this post we will learn how to replace NAs, i.e. missing values with zeros in data frame in R. With tidyr’s replace_na() function, we can replace NAs in specific columns of a dataframe to zero or any other specific value. We will start with learning how to use replace_na() to replace NAs in a… Continue reading How to replace NAs with zero in a dataframe

tidyr unite(): combine multiple columns into one

In this tutorial, we will learn how to use unite() function in tidyr package to combine multiple columns into a single column. By combining , we mean to concatenate the values of two or more columns separated by a delimiter like underscore. We will start with combining two columns into one column using three examples.… Continue reading tidyr unite(): combine multiple columns into one

Exit mobile version