StringMethods.split(pat=None, n=-1, return_type='series')

Split each string (a la re.split) in array by given pattern, propagating NA values

Parameters :

pat : string, default None

String or regular expression to split on. If None, splits on whitespace

n : int, default None (all)

return_type : {‘series’, ‘frame’}, default ‘series

If frame, returns a DataFrame (elements are strings) If series, returns an Series (elements are lists of strings).

Returns :

split : array


Both 0 and -1 will be interpreted as return all splits