A method for habitat assessment in agricultural landscapes