• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Rstats 101

Learn R Programming Tips & Tricks for Statistics and Data Science

  • Home
  • About
    • Privacy Policy
  • Show Search
Hide Search

Computing Correlation Between Multiple Variables in a dataframe

rstats101 · August 21, 2022 ·

Compute correlations between multiple variables in a dataframe

corrr package part of tidymodels meta R packages can compute correlation between multiple variables and offers tools further dissect and visualize the correlation. In this tutorial, we will learn how to use correlate() function corrr package to compute correlation all numerical … [Read more...] about Computing Correlation Between Multiple Variables in a dataframe

Filed Under: correlations in R Tagged With: compute correlation in R, corrr R package

Computing Correlation with R

rstats101 · August 17, 2022 ·

In this tutorial, we will learn how to compute correlation between two numerical variables in R using cor() function available in base R. Correlation between two numerical variables can range from -1 to +1, where -ve values suggest these two variables negatively correlated … [Read more...] about Computing Correlation with R

Filed Under: cor() in R Tagged With: compute correlation in R, pearson correlation in R, spearman correlation in R

dplyr between(): find if numerical values are within a range.

rstats101 · August 17, 2022 ·

In this tutorial we will learn how to use dplyr's between() function to find if one or more numerical values are in a range using multiple examples. We will first start with a single numeric value and find out if it is within a range. And then in the next example, we will use a … [Read more...] about dplyr between(): find if numerical values are within a range.

Filed Under: dplyr between() Tagged With: dplyr's between() to find if numerical values are in a range

How to Randomly Replace Values of Numerical Columns in a dataframe to NAs

rstats101 · August 16, 2022 ·

In this tutorial, we will learn how to randomly replace values of numerical columns in a dataframe to NAs or missing values. We will use dplyr's across() function to select only the numerical columns from a dataframe and probabilistically select certain percent of elements to … [Read more...] about How to Randomly Replace Values of Numerical Columns in a dataframe to NAs

Filed Under: dplyr across(), NAs in R Tagged With: randomly replace values to NAs

How to Randomly Replace Values in a Matrix to NAs

rstats101 · August 16, 2022 ·

In this tutorial, we will see how to randomly replace values in a matrix to NAs, missing values. We will first create some data matrix by simulation. Here we create a matrix with 20 rows and 5 columns. The data matrix is complete without any missing values. To … [Read more...] about How to Randomly Replace Values in a Matrix to NAs

Filed Under: NAs in R Tagged With: randomly replace values to NAs

  • « Go to Previous Page
  • Page 1
  • Interim pages omitted …
  • Page 12
  • Page 13
  • Page 14
  • Page 15
  • Page 16
  • Interim pages omitted …
  • Page 24
  • Go to Next Page »

Primary Sidebar

Recent Posts

  • How to create a nested dataframe with lists
  • How to compute proportion with tidyverse
  • How to Compute Z-Score of Multiple Columns
  • How to drop unused level of factor variable in R
  • How to compute Z-score

Categories

%in% arrange() as.data.frame as_tibble built-in data R colSums() R cor() in R data.frame dplyr dplyr across() dplyr group_by() dplyr rename() dplyr rowwise() dplyr row_number() dplyr select() dplyr slice_max() dplyr slice_sample() drop_na R duplicated() gsub head() impute with mean values is.element() linear regression matrix() function na.omit R NAs in R near() R openxlsx pivot_longer() prod() R.version replace NA replace NAs tidyverse R Function rstats rstats101 R version scale() sessionInfo() t.test() tidyr tidyselect tidyverse write.xlsx

Copyright © 2025 · Daily Dish Pro on Genesis Framework · WordPress · Log in

Go to mobile version