mapReduce() public method
Generates 'map-reduce' command. See also https://docs.mongodb.com/manual/core/map-reduce/.
public array mapReduce ( $collectionName, $map, $reduce, $out, $condition = [], $options = [] )$collectionName string
Collection name. $map \MongoDB\BSON\Javascript|string
Function, which emits map data from collection. Argument will be automatically cast to \MongoDB\BSON\Javascript. $reduce \MongoDB\BSON\Javascript|string
Function that takes two arguments (the map k