Man pages for xegaDerivationTrees
Generating and Manipulating Derivation Trees

addEAdd an edge or a list of edges to the data frame for edges.
addVAdd a vertex to the data frame for vertices.
booleanGrammarA constant function which returns the BNF (Backus-Naur Form)...
chooseNodeRandomly selects an attributed node in an attributed node...
chooseRuleSelects a production rule index at random from a vector of...
chooseRulekSelects k-th production rule index from a vector of...
compatibleSubtreesTest the compatibility of subtrees.
compileBNFCompile a BNF (Backus-Naur Form) of a context-free grammar.
decodeAndFixDTDecodes (and completes) a derivation tree into a working...
decodeCDTConverts a complete derivation tree into a program.
decodeDTDecodes a derivation tree into a program.
decodeDTsymDecodes a derivation tree into a list of the leaf symbols of...
decodeSymVecDecodes a vector of symbols.
decodeTreeReturns a list of all symbols of a derivation tree in...
filterANLFilter an Attributed Node List (ANL) of a derivation tree by...
filterANLidFilter an Attributed Node List (ANL) of a derivation tree by...
generateCDTGenerates a complete derivation tree from an integer vector.
generateDerivationTreeGenerates a derivation tree from an integer vector.
leavesIncompleteDTReturns the list of symbol identifiers of the leaves of a...
newEReturns empty data frame for edges.
newVReturns empty data frame for vertices.
printDerivationsPrint derivations.
randomDerivationTreeGenerates a random derivation tree.
rndPartitionRandomly partitions n in k parts.
rndsubTransforms a non-terminal symbol into a random 1-level...
rndsubkTransforms a non-terminal symbol into a 1-level derivation...
substituteSymbolCodes the substitution of a non-terminal symbol by the...
testGenerateDerivationTreeGenerate, decode, and show 'times' derivation trees from...
treeANLBuilds an Attributed Node List (ANL) of a derivation tree.
treeChildrenReturns the children of a derivation tree.
treeExtractExtracts the subtree at position 'pos' in a derivation tree.
treeInsertInserts a subtree into a derivation tree at a 'node'.
treeLeavesMeasures the number of leaves of a complete derivation tree.
treeListDepthMeasures the depth of a (nested) list.
treeNodesMeasures the number of inner nodes in a derivation tree.
treeProbabilityThe (path) probability of generating 'tree' by grammar 'G'.
treeRootReturns the root of a derivation tree.
treeSizeMeasures the number of symbols in a derivation tree.
treeToDataFramesConvert a tree to two dataframes.
xegaDerivationTreesPackage xegaDerivationTrees
xegaDerivationTrees documentation built on April 16, 2025, 5:11 p.m.