text: CREATE FUNCTION COMPUTE_BIAS_COEFFICIENT(BIAS INT) RETURNS REAL
  AS
  $$
  DECLARE COEFFICIENT REAL DEFAULT 1;
  BEGIN
  	FOR I IN 1 .. BIAS LOOP
  		COEFFICIENT = COEFFICIENT * RANDOM();
  	END LOOP;
  	RETURN COEFFICIENT;
  END
  $$
  LANGUAGE PLPGSQL