i’m new to machine learning ,i cant able to understand the splitting mechanism by calling the function and using the split_vals function
can anyone please help me out
split_vals is a quite typical python function so I guess it’s the array “slicing” functionality that you don’t understand?
split_vals simply takes an array “a” and a number “n” and split the array into two parts. One from element 0 to element n-1 (a[:n]) and one from element n to the last element (a[n:]). It returns copies of the slices so modifying them will not affect the input array.
Thank you so much