Extracts substructure from a molecule.
substruct(mol, oldnum)
mol | molecule |
---|---|
oldnum | list of the atoms defining the substructure to be extracted |
Substructure
data("alkans74") mol <- alkans74.mdb[[2]] substruct(mol, c(1,2))#> $atoms #> $atoms[[1]] #> $atoms[[1]]$el #> [1] "C" #> #> $atoms[[1]]$nh #> [1] 3 #> #> $atoms[[1]]$ch #> [1] 0 #> #> $atoms[[1]]$x #> [1] 138 #> #> $atoms[[1]]$y #> [1] 150 #> #> $atoms[[1]]$z #> [1] 0 #> #> $atoms[[1]]$vd_ #> [1] 1 #> #> $atoms[[1]]$va_ #> [1] 4 #> #> $atoms[[1]]$pi_ #> [1] 0 #> #> $atoms[[1]]$ne_ #> [1] 2 #> #> $atoms[[1]]$bo_ #> [1] 1 #> #> #> $atoms[[2]] #> $atoms[[2]]$el #> [1] "C" #> #> $atoms[[2]]$nh #> [1] 2 #> #> $atoms[[2]]$ch #> [1] 0 #> #> $atoms[[2]]$x #> [1] 174 #> #> $atoms[[2]]$y #> [1] 136 #> #> $atoms[[2]]$z #> [1] 0 #> #> $atoms[[2]]$vd_ #> [1] 2 #> #> $atoms[[2]]$va_ #> [1] 4 #> #> $atoms[[2]]$pi_ #> [1] 0 #> #> $atoms[[2]]$ne_ #> [1] 1 3 #> #> $atoms[[2]]$bo_ #> [1] 1 1 #> #> #> #> $bonds #> $bonds[[1]] #> $bonds[[1]]$at1 #> [1] 1 #> #> $bonds[[1]]$at2 #> [1] 2 #> #> $bonds[[1]]$bo #> [1] 1 #> #> #>