Duplicated the selected view on sheet

Hi all,

I have create the script to duplicated the sheet c/w the views.
However, Can we filter the view that want to duplicated?
Example, on the sheet have the section, plan view, Reflected Ceiling plan, legend, etc.
but we only want Plan view and legend.
What do you think mate?
Duplicate Sheets with Selected Template.dyn (79.7 KB)