14(
int *incr,
int *sat,
int *etype)
const
40(
double *tout,
int *
deme,
41 int *
ell,
int *sat,
int *etype)
const
43 size_t nd =
ndeme()+1;
45 for (
size_t j = 0; j < nd; j++) {
51 for (
const node_t *p : *
this) {
52 if (tcur < p->slate) {
53 tout += nd;
ell += nd; sat += nd;
54 deme += nd; etype += nd;
56 for (
size_t j = 0; j < nd; j++) {
66 tout += nd;
ell += nd; sat += nd;
67 deme += nd; etype += nd;
69 for (
size_t j = 0; j < nd; j++) {
82 SEXP tout,
deme,
ell, sat, etype, out, outn;
84 int nl = (
ndeme()+1)*nt;
85 PROTECT(tout = NEW_NUMERIC(nl));
86 PROTECT(
deme = NEW_INTEGER(nl));
87 PROTECT(
ell = NEW_INTEGER(nl));
88 PROTECT(sat = NEW_INTEGER(nl));
89 PROTECT(etype = NEW_INTEGER(nl));
90 PROTECT(out = NEW_LIST(5));
91 PROTECT(outn = NEW_CHARACTER(5));
99 INTEGER(sat),INTEGER(etype));
Balls function as pointers.
name_t deme(void) const
view deme
SEXP lineage_count(void) const
lineage count and saturation
size_t ndeme(void) const
number of demes
slate_t & timezero(void)
view/set zero time.
slate_t & time(void)
view/set current time.
Encodes a genealogical node.
name_t deme(void) const
view deme
void lineage_incr(int *incr, int *sat, int *etype) const
bool holds_own(void) const
size_t ntime(slate_t t) const
Number of distinct timepoints.
bool holds(ball_t *b) const
does this node hold the given ball?
static int set_list_elem(SEXP list, SEXP names, SEXP element, const char *name, int pos)