Find Skewed Features with {healthyR.ai}

code
rtip
healthyrai
skew
Author

Steven P. Sanderson II, MPH

Published

November 14, 2022

Introduction

Sometimes we may want to quickly find skewed features in a data set. This is easily achiveable using the {healthyR.ai} library. There is a simple function called hai_skewed_features(). We are going to go over this function today.

Function

Let’s first take a look at the function call.

hai_skewed_features(
  .data, 
  .threshold = 0.6, 
  .drop_keys = NULL
  )

Now let’s take a look at the arguments that go to the parameters of the function.

  • .data - The data.frame/tibble you are passing in.
  • .threshold - A level of skewness that indicates where you feel a column should be considered skewed.
  • .drop_keys - A c() character vector of columns you do not want passed to the function.

Example

Here are a couple of examples.

library(healthyR.ai)

hai_skewed_features(mtcars)
[1] "mpg"  "hp"   "carb"
hai_skewed_features(mtcars, .drop_keys = "hp")
[1] "mpg"  "carb"