Update-only bulk edit of arbitrary metadata columns on rows
that are already present in the aedes_main FlyTable. Every root_id
must already be present, otherwise nothing is written – use
aedes_add_neurons() to create rows, and aedes_set_group() when the
only column you need to touch is group.
Usage
aedes_set_meta(
ids = NULL,
df = NULL,
dryrun = TRUE,
update_roots = TRUE,
annotator = TRUE,
proofreader = FALSE,
wipe = FALSE,
...
)Arguments
- ids
root_ids in any form understood by
aedes_ids()(including a query string); or, whendfisNULL, a data.frame of metadata that itself contains aroot_idcolumn.- df
an optional data.frame of metadata, recycled to match
ids. When supplied together withids, aroot_idcolumn is prepended fromids.- dryrun
logical: if
TRUE(the default) return the update frame without writing to FlyTable.- update_roots
whether to bring
root_ids to the pinned timestamp withfafbseg::flywire_latestid()before matching.- annotator
Multi-select
annotatorcolumn write policy.TRUE(the default) appendsgetOption("aedes.initials")to the existing cell;FALSEleaves the column alone; a character vector (or comma-joined string) appends those tokens explicitly.- proofreader
Multi-select
proofreadercolumn write policy. Same accepted values asannotator; defaults toFALSE.- wipe
If
TRUE, replace the target multi-select column(s) with just the new tokens instead of merging with existing cell contents. DefaultFALSE(append).- ...
reserved (used to reject a mistaken
dry_runargument).
Value
a data.frame of the rows written (or, on a dry run, that would be
written), keyed by FlyTable _id.
Details
Rows with status bad_nucleus, duplicate or not_a_neuron are
dropped before updating; any remaining root_id not found in aedes_main
is an error (nothing is written). Writes go through the shared update engine,
which pins a single timestamp so join-by-root_id is reliable.
See also
aedes_add_neurons() to add rows that are not yet present;
aedes_set_group() for the dedicated group-only path;
aedes_meta() to query the same table.
Examples
if (FALSE) { # \dontrun{
options(aedes.initials = "GJ")
# Update a handful of neurons: two columns, recycled across all ids.
ids <- c("648518347569414567", "648518347399768369")
aedes_set_meta(ids,
data.frame(cell_type = c("KCa'b'", "KCg"),
status = "adequate"))
# Or pass a single data.frame that already carries `root_id`
df <- data.frame(root_id = ids,
cell_type = c("KCa'b'", "KCg"),
status = "adequate",
stringsAsFactors = FALSE)
aedes_set_meta(df) # dry run (default)
aedes_set_meta(df, dryrun = FALSE) # commit
# Query-string ids also work: update every ALPN with a note
aedes_set_meta("class:ALPN",
data.frame(notes = "reviewed 2026-09"),
dryrun = FALSE)
} # }