powered by
Z-score method is used to calculate the standardization value of data.The formula is (x-mean(x))/var(x). It can compress the data into the (0,1).
Z_score(data, dataframe = FALSE)
Your input data, which can be numerci or data.frame
Wether the data is dataframe. The default is False(numeric)
Calculate the Z_score standardization of the dataset by the formula: (x-mean(x))/var(x)
# NOT RUN { ##For the numeric data data(iris,package = 'datasets') w<-Z_score(iris[,1]) print(w) ##For the data.frame data w1<-Z_score(iris[,-5],dataframe=TRUE) print(w1) # }
Run the code above in your browser using DataLab