Python Array And Numpy Mean Function In R