function filterRegExp (array, regexp) {
  if (arraySize(array).length !== 1) {
    throw new Error('Only one dimensional matrices supported')
  }

  return Array.prototype.filter.call(array, (entry) => regexp.test(entry))
}
Filter values in an array given a regular expression
@param {Array} array
@param {RegExp} regexp
@return {Array} Returns the filtered array
@private