Banking, insurance and financeBI, AI and ML for the business
Portfolio risk and correlations
A diversified portfolio stays diversified only while correlations hold. Muvia reads fund prices minute by minute, a Python function works out volatility and drawdown, Analysis aligns the spikes, and the committee sees the correlation flip sign before the monthly statement does.
Illustrative scenario: it describes a typical case, not a customer project.
Diversification breaks exactly when you need it.
Equities and bonds usually offset each other, and the portfolio is built on that. In a crisis the correlation can flip sign within days, and a monthly statement shows it once the loss is already made.
Seeing it in time takes frequent prices, volatility and drawdown worked out the same way every time, and a way to compare spikes with each other. The committee needs the numbers with an explanation, not a spreadsheet to decode.
- Who it's for
- Risk managers, portfolio managers, the investment committee and quantitative analysts.
In Muvia, step by step
Real product screens, recorded on a project with sample data.
The video · A diversified portfolio stays diversified only while correlations hold. Muvia reads fund prices minute by minute, a Python function works out volatility and drawdown, Analysis aligns the spikes, and the committee sees the correlation flip sign before the monthly statement does.
What you get
- One definition of risk
- Volatility and drawdown always come from the same function: committee, portfolio managers and risk managers read the same numbers.
- A spike compared with the others
- Overlaid episodes show whether today's looks like the earlier ones or not, in shape and in length.
- A shifting correlation shows
- The dashboard shows when equities and bonds stop offsetting each other, while it happens.
- A note for the committee, not a spreadsheet
- Numbers, charts and the proposal arrive in one document, rebuilt on fresh data.
For the technical team
How it is built in Muvia
- 1
Connect prices and positions
Prices arrive from a REST API on a schedule, positions from the securities system with an incremental copy. Every source becomes a table you can query.
- 2
Work out risk in Python
A function works out each fund's bands, annualised volatility over a rolling window and drawdown from the peak. A flow runs it on a schedule and writes the results to a managed table.
- 3
Align the spikes in Analysis
The Layers view overlays high-volatility episodes on the moment they start: today's spike is compared with past ones by shape and length. The team's notes stay on the chart.
- 4
Follow the correlation
A dashboard puts hourly candles, fund volatility and the rolling correlation between equities and bonds side by side; an alarm opens when volatility breaks its limit.
- 5
Write the note for the committee
A notebook with text, numbers and charts tells what changed and the proposed reallocation, and becomes a PDF for the committee.
Python function
import numpy as np
MINUTES_PER_YEAR = 252 * 510 # trading days times trading minutes
def transform(inputs, params, ctx):
df = inputs["rows"].sort_values(["fund", "minute"])
w = params["window_minutes"]
price = df.groupby("fund")["price"]
df["return"] = price.transform(lambda p: np.log(p).diff())
df["annual_volatility"] = df.groupby("fund")["return"].transform(
lambda r: r.rolling(w).std() * np.sqrt(MINUTES_PER_YEAR))
df["drawdown"] = df["price"] / price.cummax() - 1
mean = price.transform(lambda p: p.rolling(w).mean())
std = price.transform(lambda p: p.rolling(w).std())
df["upper_band"], df["lower_band"] = mean + 2 * std, mean - 2 * std
ctx.logger.info("funds processed: %d", df["fund"].nunique())
return {"rows": df}- The data it needs
- Fund prices by the minute, read from the market-data provider's REST API
- Portfolio positions and weights, from the securities system on SQL Server
- Volatility and drawdown limits per fund, from an Excel file
More cases in this line
All use cases- Card payment fraudEvery card payment leaves a row: amount, merchant, country, time. In Muvia a Python function written by your team compares each payment with the customer's habits and gives it a score that says why, and an alarm tells the fraud team when suspicious payments start to cluster.
- Customer 360 and segmentationPayments, chargebacks, support and newsletter live in four different systems. Muvia joins them customer by customer, every Monday a Python function sorts customers into segments by recency, frequency and value, with the reason, and Athena says whom to call back and prepares the list for the branches.
- Motor claims and the black boxThe claim describes a crash, the black box records speed, braking and acceleration. Muvia puts them side by side: every claim second by second, a Python score recomputed every morning, and the claims office knows which claims to send to an adjuster and which to pay right away.
Bring us a question you can't answer today.
We start from a real question your business has and walk the path from source to dashboard with your systems, not a demo dataset.