Answers for "calculate mean in python using numpy"

4

numpy average

import numpy as np 
a = np.arange(6).reshape(3,2) 
average = np.average(a)
Posted by: Guest on November-23-2020
0

calculate mean on python

def calculate_mean(n):
    s = sum(n)
    N = len(n)
    
    mean = s / N
    
    return mean
Posted by: Guest on December-28-2020

Code answers related to "calculate mean in python using numpy"

Python Answers by Framework

Browse Popular Code Answers by Language