Saturday, November 24, 2012

R normalize data into 0-1 Interval


function normalize(data)
{
  maxvalues = apply(data,2,max)
  minvalues = apply(data,2,min)
  sweep(data,2,minvalues,"-")
  sweep(data,2,maxvalues-minvalues,"/")
}

No comments:

AI

Despite the benefits of AI we are starving for humanity.