Description Usage Arguments Details Value
View source: R/Transformations.R
VariableTransform initially pads the data inorder to eliminates all negative and zero values and then categorizes the data into normal, positive skewed and negative skewed based on the skewness score of each column of the given data frame
Transformation for Positive skewed data:
Different transformation techiniques considered to transform positive skewed data are as follows:
Log Transformation
Square Root Transformation
Cube Root Transformation
Turkey Power Transformation
Box-Cox Power Transformation
Yeo-Johnson Transformation
Order-Norm Transformation
Lambert-W Transformation
Of all these techniques, Best technique is choosed based on the "ChooseBestTrans" argument provided.Default method will be Shapiro P-Value
Transformation for Negative skewed data:
Different transformation techiniques considered to transform negative skewed data are as follows:
Square Transformation
Cube Transformation
Turkey Power Transformation
Box-Cox Power Transformation
Yeo-Johnson Transformation
Order-Norm Transformation
Lambert-W Transformation
Of all these techniques, Best technique is choosed based on the "ChooseBestTrans" argument provided.Default method will be Shapiro P-Value
Scaling the dataset:
After merging all the datasets created (normally distributed data, positive skewd data, neggative skewed data), entire dataset is normalized and stored in an other dataframe.
1 | VariableTransform(data_col, best_trans_metric = "Shapiro P Value")
|
data_col |
Any continuous data vector that has to transformed into normal form |
best_trans_metric |
Considers the best transformation based on one of the three values ("Shapiro P Value", "Pearson P Value", "Min skewness") |
Takes in a data vector and performs the best possible transformation to each of the columns in the data frame
Returns a list of 7 objects:
Tranformed Dataset for all Continuous variables
Scaled Dataset for all Continuous variables
Distribution of the dataset provided
Intermediate scores (for all the techniques) for Positive skewed data
Intermediate scores (for all the techniques) for Positive skewed data
A list of model fit file, OrderNorm objects and tau_mat objects
Combination of transformed continuous data and categorical data
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.