Adds option to uniformly or randomly sample rows