group_data
Group and aggregate CSV data by specified columns using functions like sum, mean, count, min, max, or std to analyze and summarize datasets.
Instructions
Group and aggregate CSV data.
Args:
filename: Name of the CSV file
group_by: Column name or list of column names to group by
aggregations: Dictionary mapping column names to aggregation functions
(sum, mean, count, min, max, std, etc.)
Returns:
Dictionary with grouped and aggregated data
Input Schema
Name | Required | Description | Default |
---|---|---|---|
aggregations | Yes | ||
filename | Yes | ||
group_by | Yes |
Input Schema (JSON Schema)
{
"properties": {
"aggregations": {
"additionalProperties": {
"type": "string"
},
"title": "Aggregations",
"type": "object"
},
"filename": {
"title": "Filename",
"type": "string"
},
"group_by": {
"anyOf": [
{
"type": "string"
},
{
"items": {
"type": "string"
},
"type": "array"
}
],
"title": "Group By"
}
},
"required": [
"filename",
"group_by",
"aggregations"
],
"type": "object"
}