Here you can find the source of randomScalingFactor()
public static double randomScalingFactor()
//package com.java2s; //License from project: Open Source License public class Main { public static double randomScalingFactor() { return (double) (Math.random() > 0.5 ? 1.0 : -1.0) * Math.round(Math.random() * 100); }//from w w w . j a v a 2 s . c o m }