I would like add one group into another (already existing one) in layerTreeRoot using PyQGIS.
How can i do it?
Adding layer group using PyQGIS? is not the answer to my question, because it allows only to create 2 groups at the same time. Group and sub group.
myOriginalGroup) where you want to place your new group. Then just use amyNewGroup = myOriginalGroup.addGroup("My New Group")and you're done. See also this answer (https://gis.stackexchange.com/questions/66169/adding-layer-group-using-pyqgis/134377#134377) for reference, namely where I mention nested groups. – Germán Carrillo Oct 28 '19 at 13:07