Alpha diversity measures for individual phyla

It’d be sweet if there were a way to calculate diversity for selected phyla/genera/etc without having to run get linage on each one. I’m thinking of process where you can give a list of the interesting taxa (sort of like an accnos), subsample repeatedly for the alpha div measures (summary.single) but for each subsample calculate the div measure for each of the selected taxa. I feel like this is something that I should be able to write a for loop to do with existing mothur commands but I’m not having any success.

ETA, The reason this would be awesome is to dive into why I’m seeing treatment effects on the relative abundance of some phyla-is there an increase in many OTUs or just a few? My samples are incredibly diverse soils. Indicator species and random forest have not proved efficient at selecting OTUs that explain the differences I can see in the beta diversity