def correlation_sums(indicators, max_dim):
 corrsums = np.zeros((1, max_dim))
 (corrsums[(0, 0)], indicators) = correlation_sum(indicators, 1)
 for i in range(1, max_dim):
  (corrsums[(0, i)], indicators) = correlation_sum(indicators, 2)
 return corrsums

def correlation_sums ( indicators , max_dim ) : corrsums = np . zeros ( ( 1 , max_dim ) ) ( corrsums [ ( 0 , 0 ) ] , indicators ) = correlation_sum ( indicators , 1 ) for i in range ( 1 , max_dim ) : ( corrsums [ ( 0 , i ) ] , indicators ) = correlation_sum ( indicators , 2 ) return corrsums
calculate all correlation sums for embedding dimensions 1:max_dim parameters indicators : 2d array matrix of distance threshold indicators max_dim : integer maximum embedding dimension returns corrsums : 1d array correlation sums .