Fixed coercion issue. Was previously a matrix. Now correctly returns a data.frame