Adds the specified individual to this dataset.
426750
def addIndividual(self, individual):
        
        id_ = individual.getId()
        self._individualIdMap[id_] = individual
        self._individualIds.append(id_)
        self._individualNameMap[individual.getName()] = individual
1243155
def add(self, personID, edgeID, pos, depart=DEPART_NOW, typeID="DEFAULT_PEDTYPE"):
        
        if depart > 0:
            depart *= 1000
        self._connection._beginMessage(tc.CMD_SET_PERSON_VARIABLE, tc.ADD, personID,
                                       1 + 4 + 1 + 4 + len(typeID) + 1 + 4 + len(edgeID) + 1 + 4 + 1 + 8)
        self._connection._string += struct.pack("!Bi", tc.TYPE_COMPOUND, 4)
        self._connection._packString(typeID)
        self._connection._packString(edgeID)
        self._connection._string += struct.pack("!Bi", tc.TYPE_INTEGER, depart)
        self._connection._string += struct.pack("!Bd", tc.TYPE_DOUBLE, pos)
        self._connection._sendExact()
1125385
def insertDataset(self, dataset):
        
        try:
            models.Dataset.create(
                id=dataset.getId(),
                name=dataset.getLocalId(),
                description=dataset.getDescription(),
                attributes=json.dumps(dataset.getAttributes()))
        except Exception:
            raise exceptions.DuplicateNameException(
                dataset.getLocalId())
373967
private StatementResult addPerson( final Transaction tx, final String name )
    {
        return tx.run( "CREATE (:Person {name: $name})", parameters( "name", name ) );
    }
1042628
def addBiosample(self):
        
        self._openRepo()
        dataset = self._repo.getDatasetByName(self._args.datasetName)
        biosample = bio_metadata.Biosample(
            dataset, self._args.biosampleName)
        biosample.populateFromJson(self._args.biosample)
        self._updateRepo(self._repo.insertBiosample, biosample)
932626
def add_data(self, data):  # add append option later
        
        df = pd.DataFrame(data)
        name, dtype = self.get_singular_and_plural_dtype(self.dtype)
        if name in df.columns:
            df.index = df[name]
        df.index.name = name + " name"
        self.df = df
606830
def add(config, username, filename):
        """"""
        try:
            client = Client()
            client.prepare_connection()
            user_api = UserApi(client)
            key_api = API(client)
            key_api.add(username, user_api, filename)
        except (ldap3.core.exceptions.LDAPNoSuchAttributeResult,
                ldap_tools.exceptions.InvalidResult,
                ldap3.core.exceptions.LDAPAttributeOrValueExistsResult
                ) as err:  # pragma: no cover
            print('{}: {}'.format(type(err), err.args[0]))
        except Exception as err:  # pragma: no cover
            raise err from None
256972
def add(self, data):
        """"""
        assert isinstance(data, bytes)
        with self.lock:
            self.buf += data
1347840
def addmember(self, value):
        

        if value is not None and not isinstance(value, Agent):
            value = Agent(value)

        self._member.append(value)
1002052
def add(self, name, value):
        
        # We just clear the table if the entry is too big
        size = table_entry_size(name, value)
        if size > self._maxsize:
            self.dynamic_entries.clear()
            self._current_size = 0

        # Add new entry if the table actually has a size
        elif self._maxsize > 0:
            self.dynamic_entries.appendleft((name, value))
            self._current_size += size
            self._shrink()
150204
def add_identifier(self, name, obj):
        

        name = str(name)
        self._known_identifiers[name] = obj
499254
def add_information_about_person(self, session_info):
        """"""

        session_info = dict(session_info)
        name_id = session_info["name_id"]
        issuer = session_info.pop("issuer")
        self.cache.set(name_id, issuer, session_info,
                       session_info["not_on_or_after"])
        return name_id
1305510
def add_user(self, **kwargs):
        """"""
        user = self.UserClass(**kwargs)
        if hasattr(user, 'active'):
            user.active = True
        self.db_adapter.add_object(user)
        return user
259077
def AddUser(self, uid, username, active):
    '''
    '''
    user_path = '/org/freedesktop/login1/user/%i' % uid
    if user_path in mockobject.objects:
        raise dbus.exceptions.DBusException('User %i already exists' % uid,
                                            name=MOCK_IFACE + '.UserExists')

    self.AddObject(user_path,
                   'org.freedesktop.login1.User',
                   {
                       'Sessions': dbus.Array([], signature='(so)'),
                       'IdleHint': False,
                       'DefaultControlGroup': 'systemd:/user/' + username,
                       'Name': username,
                       'RuntimePath': '/run/user/%i' % uid,
                       'Service': '',
                       'State': (active and 'active' or 'online'),
                       'Display': ('', dbus.ObjectPath('/')),
                       'UID': dbus.UInt32(uid),
                       'GID': dbus.UInt32(uid),
                       'IdleSinceHint': dbus.UInt64(0),
                       'IdleSinceHintMonotonic': dbus.UInt64(0),
                       'Timestamp': dbus.UInt64(42),
                       'TimestampMonotonic': dbus.UInt64(42),
                   },
                   [
                       ('Kill', 's', '', ''),
                       ('Terminate', '', '', ''),
                   ])

    return user_path
1291702
def add(self, model):
        
        if isinstance(model, (Regressor, Classifier)):
            self.models.append(model)
        else:
            raise ValueError('Unrecognized estimator.')
333858
def addContinuousSet(self):
        
        self._openRepo()
        dataset = self._repo.getDatasetByName(self._args.datasetName)
        filePath = self._getFilePath(self._args.filePath,
                                     self._args.relativePath)
        name = getNameFromPath(self._args.filePath)
        continuousSet = continuous.FileContinuousSet(dataset, name)
        referenceSetName = self._args.referenceSetName
        if referenceSetName is None:
            raise exceptions.RepoManagerException(
                "A reference set name must be provided")
        referenceSet = self._repo.getReferenceSetByName(referenceSetName)
        continuousSet.setReferenceSet(referenceSet)
        continuousSet.populateFromFile(filePath)
        self._updateRepo(self._repo.insertContinuousSet, continuousSet)
1336636
def add_subject(self, ind_id, sex=None, phenotype=None):
        

        self.pedigree_data[ind_id] = len(self.phenotype_data[0])
        if phenotype != None:
            if type(self.phenotype_data) is list:
                self.phenotype_data[0].append(phenotype)
            else:
                self.phenotype_data[-1, len(self.individual_mask)] = phenotype
        self.individual_mask.append(0)

        if PhenoCovar.sex_as_covariate:
            try:
                self.covariate_data[0].append(float(sex))
            except Exception, e:
                raise MalformedInputFile("Invalid setting, %s, for sex in pedigree" % (sex))