1# Basic syntax:
2df = df.sample(frac=1, random_state=1).reset_index(drop=True)
3# Where:
4# - frac=1 specifies returning 100% of the original rows of the
5# dataframe (in random order). Change to a decimal (e.g. 0.5) if
6# you want to sample say, 50% of the original rows
7# - random_state=1 sets the seed for the random number generator and
8# is useful to specify if you want results to be reproducible
9# - .reset_index(drop=True) specifies resetting the row index of the
10# shuffled dataframe