simple normalise function

This commit is contained in:
AG Damsbo 2021-11-12 08:10:18 +01:00
parent 64ead1da46
commit 364bbe290e

8
fun/normalize.R Normal file
View File

@ -0,0 +1,8 @@
normalize<-function(x){
n<-(x-min(x))/(max(x)-min(x))
return(n)
}
# Example:
# c<-c(1,2,4,5,6,8,3,8)
# normalize(c)