powered by
shannon.entropy(p)
x<-sample(1:500,50) p<-x/sum(x) shannon.entropy(p)
Run the code above in your browser using DataLab