Something like this?
jQuery.each(stateList, function () {
var state = this; // Cache the state string.
jQuery( ".products[data-state~='" + state + "']" ).fadeIn(300, function(){
jQuery( ".product[data-state~='" + state +"']" ).show();
});
});