Not fully understanding what you require, I would suggest you look at a tracking method if the frequency is changing during the test duration. There will be transitions as the frequency changes and the only way I can think of is to actively track the frequency as is done in active-noise-cancelling headphones. Only then will you be able to ascertain any SNR.
I cannot see it being done in something like Matlab unless you can create a script to follow the frequency and that sounds like a very complex undertaking to me.
But, then, I have been wrong before.