Internal functions to generate model matrices
by_source_model_matrix(formula_parts, data_sources)A list of matrices
Sources describe the data.frames holding the original information on the nodes and the node pairs. There are three possible source data.frame which are referred to as "pair", "orig", or "dest". All formulas (normal, sdm, and instrument) are combined to generate an overall model matrix which is only expanded once for each source.