<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def simple_moving_average(x, n=10):
 """ Calculate simple moving average Parameters x : ndarray A numpy array n : integer The number of sample points used to make average Returns ------- ndarray A 1 x n numpy array instance """

    if x.ndim > 1 and len(x[0]) > 1:
        x = np.average(x, axis=1)
    a = np.ones(n) / float(n)
    return np.convolve(x, a, 'valid')