Math & Numbers
Compare two independent proportions with a pooled two-proportion Z test and confidence interval
Call this tool from your code in three languages.
curl -X POST 'https://api.elysiatools.com/en/api/tools/two-proportion-z-test-calculator' \
-H 'Content-Type: application/json' \
-d '{"group1Successes":60,"group1Trials":100,"group2Successes":45,"group2Trials":100,"hypothesizedDifference":0,"alternative":"two-sided","alpha":0.05,"decimalPlaces":4}'Send a POST request with your inputs as JSON. File parameters require a separate upload first.
POST https://api.elysiatools.com/en/api/tools/two-proportion-z-test-calculator| Name | Type | Required | Description |
|---|---|---|---|
| group1Successes | number | No | — |
| group1Trials | number | No | — |
| group2Successes | number | No | — |
| group2Trials | number | No | — |
| hypothesizedDifference | number | No | — |
Add this tool to your Model Context Protocol server so AI agents can list and call it.
Add this block to your MCP client configuration:
{
"mcpServers": {
"elysiatools-two-proportion-z-test-calculator": {
"name": "two-proportion-z-test-calculator",
"description": "Compare two independent proportions with a pooled two-proportion Z test and confidence interval",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=two-proportion-z-test-calculator",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}After connecting to the SSE endpoint, list the exposed tools:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Invoke the tool by its id, passing arguments built from its parameters:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "two-proportion-z-test-calculator",
"arguments": {
"group1Successes": 60,
"group1Trials": 100,
"group2Successes": 45,
"group2Trials": 100,
"hypothesizedDifference": 0,
"alternative": "two-sided",
"alpha": 0.05,
"decimalPlaces": 4
}
}
}Questions or issues? Contact [email protected]
| alternative |
| select |
| No |
| — |
| alpha | number | No | — |
| decimalPlaces | number | No | — |
JSON result
{
"key": {...},
"metadata": {
"key": "value"
},
"error": "Error message (optional)",
"message": "Notification message (optional)"
}