Add an outcome against the rating
505588
def add(other_rating, score)
      g, e = other_rating.gravity_expected_score(rating.mean)
      @v_pre += g**2 * e * (1 - e)
      @delta_pre += g * (score - e)
    end
1358262
def set_result(self, result):
        """"""

        if self.is_finished():
            raise InternalError("set_result called on finished AsynchronousResponse",
                                result=self._result, exception=self._exception)

        self._result = result
        self.finish()
852804
def add_to_results(self, data, label, results):
        
        raise NotImplementedError(
            '{} must specify how to add data to the running results tally '
            'by overriding the `add_to_results` method.'.format(
                self.__class__.__name__
            )
        )
109011
def add_failure(self):
        
        failure_time = time.time()

        if not self.first_failure_time:
            self.first_failure_time = failure_time

        self.failures.append(failure_time)
479790
public static function add_rating_returns() {

        return new external_single_structure(
            array(
                'success' => new external_value(PARAM_BOOL, 'Whether the rate was successfully created'),
                'aggregate' => new external_value(PARAM_TEXT, 'New aggregate', VALUE_OPTIONAL),
                'count' => new external_value(PARAM_INT, 'Ratings count', VALUE_OPTIONAL),
                'itemid' => new external_value(PARAM_INT, 'Rating item id', VALUE_OPTIONAL),
                'warnings'  => new external_warnings(),
            )
        );
    }
71994
def update_rating(self, postid):
        '''
        
        '''
        post_data = self.get_post_data()
        rating = float(post_data['rating'])
        postinfo = MPost.get_by_uid(postid)
        if postinfo and self.userinfo:
            MRating.update(postinfo.uid, self.userinfo.uid, rating=rating)
            self.update_post(postid)
        else:
            return False
739499
def add_result(key, text)
      if @result[key]
        if @result[key].is_a? Array
          @result[key].push(text)
        else
          @result[key] = [@result[key], text]
        end
      else
        @result[key] = text
      end
    end
531371
def addRating(self, rating=5.0):
        """"""
        if rating > 5.0:
            rating = 5.0
        elif rating < 1.0:
            rating = 1.0
        url = "%s/addRating" % self.root
        params = {
            "f": "json",
            "rating" : "%s" % rating
        }
        return self._post(url,
                             params,
                             proxy_port=self._proxy_port,
                             securityHandler=self._securityHandler,
                             proxy_url=self._proxy_url)
415220
def _add_results(self, results, trial_id):
        
        for result in results:
            self.logger.debug("Appending result: %s" % result)
            result["trial_id"] = trial_id
            result_record = ResultRecord.from_json(result)
            result_record.save()
673560
def move_to_result(self, lst_idx):
        """"""
        self.in_result_idx.add(lst_idx)

        if lst_idx in self.not_in_result_root_match_idx:
            self.not_in_result_root_match_idx.remove(lst_idx)
455339
def add_dummy_scores(iteratable, score=0):
    """"""
    for seq in iteratable:
        seq.letter_annotations["phred_quality"] = (score,)*len(seq)
        yield seq
1057123
def add score, v
      ret = redis.zadd rediskey, score, to_redis(v)
      update_expiration
      ret
    end
1295944
def add_success(self, group=None, type_='', field='', description=''):
        """"""
        group = group or '(200)'
        group = int(group.lower()[1:-1])
        self.retcode = self.retcode or group
        if group != self.retcode:
            raise ValueError('Two or more retcodes!')
        type_ = type_ or '{String}'
        p = Param(type_, field, description)
        self.params['responce'][p.field] = p
314253
def result(self, result):
        
        if result is None:
            raise ValueError("Invalid value for `result`, must not be `None`")  # noqa: E501
        allowed_values = ["OK", "ERROR"]  # noqa: E501
        if result not in allowed_values:
            raise ValueError(
                "Invalid value for `result` ({0}), must be one of {1}"  # noqa: E501
                .format(result, allowed_values)
            )

        self._result = result
536312
void addResult(String valueData, String detailData) {
    if (value) {
      if (valueData == null) throw new IllegalArgumentException(CLASS + ": valueData may not be null");
      values.add(valueData);
      if (detail) {
        if (detailData == null) throw new IllegalArgumentException(CLASS + ": detailData may not be null");
        details.add(detailData);
      }
    } 
    counter++;
  }
1156843
def update(self, score_vals):
        ''''''
        add = self.add
        for score, value in score_vals:
            add(score, value)
922405
def addError(self, test, err, capt=None):
        
        self.__insert_test_result(constants.State.ERROR, test, err)