public Table sample(double proportion){
  int tableCount=(int)Math.round(rowCount() * proportion);
  Selection table1Selection=new BitmapBackedSelection();
  int[] selectedRecords=generateUniformBitmap(tableCount,rowCount());
  for (  int selectedRecord : selectedRecords) {
    table1Selection.add(selectedRecord);
  }
  return selectWhere(table1Selection);
}

public Table sample ( double proportion ) { int tableCount = ( int ) Math . round ( rowCount ( ) * proportion ) ; Selection table1Selection = new BitmapBackedSelection ( ) ; int [ ] selectedRecords = generateUniformBitmap ( tableCount , rowCount ( ) ) ; for ( int selectedRecord : selectedRecords ) { table1Selection . add ( selectedRecord ) ; } return selectWhere ( table1Selection ) ; }
returns a table consisting of randomly selected records from this table . the sample size is based on the given proportion
