insertRows: insert rows as specified positions

Description Usage Arguments

View source: R/coor2index.R

Description

Util to insert multiple rows at specified positions in a data.frame, expanding single-row code by user Ari B. Friedman at https://stackoverflow.com/questions/11561856/add-new-row-to-dataframe-at-specific-row-index-not-appendedlooping through new rows

Usage

1
insertRows(existingDF, newrows, r)

Arguments

existingDF

existing data.frame

newrows

rows to add to existingDF

r

positions below which rows are to be inserted, length(r) must equal nrow(newrows), and r<=nrow(existingDF)


raim/segmenTools documentation built on Nov. 9, 2018, 5:38 p.m.