Using the sample()
function I can get the random rows. Data set having 1000000
rows of data and I want to have a subset of 20000
rows. Importing random lines can be done through this solution
https://stackoverflow.com/a/22259008/8966221
reading a dataset
dataset = read_csv(file_path)
dataset_sub = dataset.sample(20000, random_state=1)
However I want to select random rows between row number 250000
to 750000
. Any possible solution in that regard?.