How to layout user-selected nodes of the diagram

Dear Support,
I want to layout the some part of diagram which is selected by user through user interface. Is it possible to layout only the nodes which are selected by user?

Thanks

an example here: Auto-Layout on only one layer

But Tree and Layered layouts both give the best results if you lay out everything.

Thank you very much…