Get the new means.

@return New means
505571
public double[][] getMeans() {
    double[][] newmeans = new double[centroids.length][];
    for(int i = 0; i < centroids.length; i++) {
      if(sizes[i] == 0) {
        newmeans[i] = means[i]; // Keep old mean.
        continue;
      }
      newmeans[i] = centroids[i];
    }
    return newmeans;
  }
947146
function() {
            var new_array = [], l = this.coeffs.length;
            for(var i=1; i<l; i++) new_array.push(this.coeffs[i].multiply(new Frac(i)));
            this.coeffs = new_array;
            return this;
        }
203404
public function getNewDOI()
    {
        // get the first active prefix for this authenticated client
        $prefix = "";
        $testStr = "";

        $client = $this->getAuthenticatedClient();


        //if this client is not in test mode grab their production prefix
        if(sizeof($client->prefixes) > 0 && $client->mode !== 'test'){
            foreach ($client->prefixes as $clientPrefix) {
                if($clientPrefix->active && $clientPrefix->is_test == 0) {
                    $prefix = $clientPrefix->prefix->prefix_value;
                    break;
                }
            }
        }
        if(sizeof($client->prefixes) > 0 && $client->mode == 'test'){
            foreach ($client->prefixes as $clientPrefix) {
                if($clientPrefix->active && $clientPrefix->is_test == 1) {
                    $prefix = $clientPrefix->prefix->prefix_value;
                    $testStr =  "TEST_DOI_";
                    break;
                }
            }
        }
        $prefix = ends_with($prefix, '/') ? $prefix : $prefix .'/';

        $doiValue = uniqid();

        return $prefix . $testStr . $doiValue;
    }
71338
public Promise getNext() {
        while( !lock.compareAndSet(false,true) ) {}
        try {
            if (nextFuture == null)
                return new Promise();
            else
                return (Promise) nextFuture;
        } finally {
            lock.set(false);
        }
    }
956622
public <F extends NumberVector> F getMeanVector(Relation<? extends F> relation) {
    return RelationUtil.getNumberVectorFactory(relation).newNumberVector(mean);
  }
948285
public static JusFragment newInstance() {
		JusFragment fragment = new JusFragment();
		Bundle args = new Bundle();
		fragment.setArguments(args);
		return fragment;
	}
1220682
public Person getMother() {
        if (!isSet()) {
            return new Person();
        }
        final Person mother = (Person) find(getToString());
        if (mother == null) {
            return new Person();
        } else {
            return mother;
        }
    }
293671
private function newPrimaryKey()
    {
        if ($this->newPrimaryKey === null) {
            $model = $this->targetModel();

            if ($this->isPrimaryKeyDifferent()) {
                $newKey = $model->key();
            } else {
                $newKey = sprintf('%s_new', $model->key());
            }

            $this->newPrimaryKey = $newKey;
        }

        return $this->newPrimaryKey;
    }
622652
public byte meanValue() {
        if (data.length == 0)
            return 0;

        int sum = 0;
        for (byte b : data)
            sum += b;
        return (byte) (sum / data.length);
    }
217042
public com.google.protobuf.ByteString
      getNewValueBytes() {
    java.lang.Object ref = newValue_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      newValue_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }
477966
public Opinion newOpinion() {
	String newId = idManager.getNextId(AnnotationType.OPINION);
	Opinion newOpinion = new Opinion(newId);
	annotationContainer.add(newOpinion, Layer.OPINIONS, AnnotationType.OPINION);
	return newOpinion;
    }
843507
public BigInteger getAndSet(BigInteger newValue) {
        while (true) {
        	BigInteger current = get();
            if (valueHolder.compareAndSet(current, newValue))
                return current;
        }
    }
838884
public Context duplicate() {
		Context newContext = new Context(session, getIndex());
		newContext.description = this.description;
		newContext.name = this.name;
		newContext.includeInRegexs = new ArrayList<>(this.includeInRegexs);
		newContext.includeInPatterns = new ArrayList<>(this.includeInPatterns);
		newContext.excludeFromRegexs = new ArrayList<>(this.excludeFromRegexs);
		newContext.excludeFromPatterns = new ArrayList<>(this.excludeFromPatterns);
		newContext.inScope = this.inScope;
		newContext.techSet = new TechSet(this.techSet);
		newContext.authenticationMethod = this.authenticationMethod.clone();
		newContext.sessionManagementMethod = this.sessionManagementMethod.clone();
		newContext.urlParamParser = this.urlParamParser.clone();
		newContext.postParamParser = this.postParamParser.clone();
		newContext.authorizationDetectionMethod = this.authorizationDetectionMethod.clone();
		newContext.dataDrivenNodes = this.getDataDrivenNodes();
		return newContext;
	}
886993
@Override
	protected Measurement[] getModelMeasurementsImpl() {
		return new Measurement[]{
				new Measurement("anomaly detections", this.numAnomaliesDetected),
				new Measurement("change detections", this.numChangesDetected), 
				new Measurement("rules (number)", this.ruleSet.size()+1)}; 
	}
1009125
public int getUnique() {
        TIntHashSet inUseSet = new TIntHashSet();
        for (int i = 0; i < length; i++) {
            inUseSet.add(get(i));
        }
        return inUseSet.size();
    }
146183
public Double getVariance() {
		if (counter == 0) {
			return Double.NaN;
		} else {
			final double mean = computeMean();
			final double meanSquare = mean * mean;
			final double squareMean = ((double) squareTotal) / counter;
			return squareMean - meanSquare;
		}
	}
754383
public Vec[] getColumnMeanVariance()
    {
        final int d = getNumNumericalVars();
        Vec[] vecs = new Vec[] 
        {
            new DenseVector(d),
            new DenseVector(d)
        };
        
        Vec means = vecs[0];
        Vec stdDevs = vecs[1];
        
        MatrixStatistics.meanVector(means, this);
        MatrixStatistics.covarianceDiag(means, stdDevs, this);
        
        return vecs;
    }