public static AFArray Mean(AFArray arr, int dim) { IntPtr ptr; Internal.VERIFY(AFStatistics.af_mean(out ptr, arr._ptr, dim)); return(new AFArray(ptr)); }
public static SuperArray Mean(SuperArray arr, uint dim) { AFArray y = CreateMajorSupportedArray(arr); IntPtr ptr; Internal.VERIFY(AFStatistics.af_mean(out ptr, y._ptr, dim)); return(new SuperArray(new AFArray(ptr))); }
public static SuperArray Mean(SuperArray arr, uint[] dims) { AFArray y = CreateMajorSupportedArray(arr); IntPtr ptr = IntPtr.Zero; foreach (var dim in dims) { Internal.VERIFY(AFStatistics.af_mean(out ptr, y._ptr, dim)); y._ptr = ptr; } return(new SuperArray(new AFArray(ptr))); }