curl --request POST \
--url https://api.fincept.in/quantlib/physics/entropy/markov-rate \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"transition_matrix": [
[
0.8,
0.15,
0.05
],
[
0.2,
0.7,
0.1
],
[
0.1,
0.2,
0.7
]
],
"base": 2.718281828459045
}
'{
"success": true,
"data": {
"entropy_rate": 0.6547
}
}{
"detail": "Invalid API key"
}{
"detail": "Insufficient credits. This endpoint requires 5 credits."
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}quantlib-physics
Calculate Markov Chain Entropy Rate
Calculates the entropy rate of a Markov chain, measuring the long-run average uncertainty per time step. The entropy rate characterizes the complexity and predictability of a stochastic process governed by Markov transitions, useful for modeling regime-switching markets and state-dependent strategies.
Use Cases:
- Measure predictability of market regime transitions
- Characterize complexity of state-based trading strategies
- Analyze credit rating transition dynamics
- Model path-dependent risk scenarios
- Assess information generation rate in stochastic processes
Formula: H_rate = -ΣΣ π_i P_ij log(P_ij), where π is stationary distribution
Credits: 5 credits per request (Pro Tier) [Tier: ENTERPRISE, Credits: 10]
POST
/
quantlib
/
physics
/
entropy
/
markov-rate
curl --request POST \
--url https://api.fincept.in/quantlib/physics/entropy/markov-rate \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"transition_matrix": [
[
0.8,
0.15,
0.05
],
[
0.2,
0.7,
0.1
],
[
0.1,
0.2,
0.7
]
],
"base": 2.718281828459045
}
'{
"success": true,
"data": {
"entropy_rate": 0.6547
}
}{
"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
Markov transition probability matrix (rows must sum to 1)
Example:
[
[0.7, 0.2, 0.1],
[0.3, 0.5, 0.2],
[0.1, 0.3, 0.6]
]
Stationary distribution (optional - will be computed if not provided)
Example:
[0.35, 0.35, 0.3]
Logarithm base for entropy calculation
Example:
2.718281828459045
⌘I
