analysis_linear_regression
Fits a least-squares linear regression to paired x and y data, returning slope, intercept, correlation, R-squared, and the equation for trend analysis.
Instructions
Fit y = slope·x + intercept by least squares. Returns slope, intercept, r, r_squared and the equation string.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"x": "<x>",
"y": "<y>"
},
"name": "analysis_linear_regression"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | Yes | ||
| y | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |