Move column to a specific position in R

The easiest way to move the data frame column to a specific position in R is by using the function relocate from package dplyr.

Find min or max for each row in R

If you want to calculate min or max for a range of columns in each row of the data frame in R, then here is how to do that easily.

How to create reproducible R data frame from existing one

Short answer – create a reproducible R data frame with function dput. Dput will give you a good reproducible piece of code that you can use for examples.

How to connect to PostgreSQL database with Excel or Power BI

Here is how to connect to the PostgreSQL database with Excel or Power BI using the ODBC data source.

Extract text based on match of multiple possible strings in R

Sometimes there are multiple possible strings that you can locate in text. If you would like to extract text in R based on the first match of multiple strings, this post is for you.

ifelse and NA problem in R

If your data frame contains NA values, then the R function ifelse might return results you don’t desire. Missing values might be a problem for ifelse. The first victory is that you are aware of that.

Exit mobile version