curl --request POST \
--url https://api.fincept.in/quantlib/physics/entropy/mutual-information \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"joint_prob": [
[
0.45,
0.05,
0
],
[
0.05,
0.4,
0.05
],
[
0,
0,
0
]
],
"base": 2.718281828459045
}
'{
"success": true,
"data": {
"mutual_information": 0.5623
}
}{
"detail": "Invalid API key"
}{
"detail": "Insufficient credits. This endpoint requires 5 credits."
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}quantlib-physics
Calculate Mutual Information
Calculates the mutual information I(X;Y) between two random variables, measuring the reduction in uncertainty of one variable due to knowledge of the other. Mutual information is symmetric, always non-negative, and captures both linear and non-linear dependencies, making it superior to correlation for detecting complex relationships.
Use Cases:
- Detect non-linear dependencies between assets
- Feature selection for predictive models
- Measure information flow between markets
- Quantify predictive relationships
- Portfolio diversification analysis
Formula: I(X;Y) = H(X) + H(Y) - H(X,Y) = H(X) - H(X|Y)
Credits: 5 credits per request (Pro Tier) [Tier: ENTERPRISE, Credits: 10]
POST
/
quantlib
/
physics
/
entropy
/
mutual-information
curl --request POST \
--url https://api.fincept.in/quantlib/physics/entropy/mutual-information \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"joint_prob": [
[
0.45,
0.05,
0
],
[
0.05,
0.4,
0.05
],
[
0,
0,
0
]
],
"base": 2.718281828459045
}
'{
"success": true,
"data": {
"mutual_information": 0.5623
}
}{
"detail": "Invalid API key"
}{
"detail": "Insufficient credits. This endpoint requires 5 credits."
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
API key for authentication. Get your key at https://api.fincept.in/auth/register
Body
application/json
⌘I
