Wraps the provided row or column of values by rows after a specified number of elements