---
title: "7.5.2 Where to work: the Spanish and European ecosystem"
description: "Hedge funds, prop trading, banks, asset managers, market makers, crypto and fintech: what each does, how it makes money and what the registers say."
url: "https://pythonparatrading.com/en/python-trading-course/level-7/quant-jobs-spain-europe-ecosystem/"
lang: "en"
image: "https://pythonparatrading.com/og/en/python-trading-course/level-7/quant-jobs-spain-europe-ecosystem.png"
---

# 7.5.2 · Where to work: what each firm does and what the registers say

> A quant works for a business model before working for a team. This lesson sorts the types of firm that hire quantitative profiles by the way they make money, measures the Spanish ecosystem with the lists and statistics of the CNMV (Spain's securities regulator) and the European one with the ESMA register, and turns those sources into code that can be run again any day. It recommends no firm.

- Course: [Level 7: Production, MLOps, regulation, career and capstone](https://pythonparatrading.com/en/python-trading-course/level-7/)
- Module: 7.5 · Quant career
- Duration: 50 min
- Prerequisites: [1.1.1 · Market participants and trading venues](https://pythonparatrading.com/en/python-trading-course/level-1/market-participants-and-trading-venues/), [4.4.1 · Choosing a broker from Spain or the EU: regulation, assets, costs and API](https://pythonparatrading.com/en/python-trading-course/level-4/choosing-a-broker-in-the-eu/), [3.7.5 · MiCA: the EU framework for crypto-assets and their service providers (CASPs)](https://pythonparatrading.com/en/python-trading-course/level-3/mica-casp-eu-crypto-regulation/)

## By the end of this lesson

- Distinguish hedge funds, proprietary trading, banks, asset managers, market makers, crypto firms and fintech by the source of their revenue and by what a quantitative profile does in them.
- Relate each type of firm to its legal form in Spain (SV, AV, SGIIC, SGEIC, EAF, credit institution, CASP) and to what that license allows it to do.
- Read and aggregate with pandas the format of the CNMV entity lists, its income statement statistics and a response from the ESMA register.
- Check a potential employer in primary sources before an interview.

## Four ways to make money

Job postings say “hedge fund”, “bank” or “fintech”, but those words group very different businesses together. What
best explains the daily work of a quantitative profile is not the name of the sector but **where the firm's revenue
comes from**: from there follow the horizon of decisions, the risk tolerance, the value of a millisecond and the way of
measuring whether someone does their job well. Lesson 7.5.1 describes the roles (researcher, developer, trader, risk,
data and ML engineer); this one places them in the places where they are practiced.

```mermaid
flowchart TB
  I[Source of revenue] --> P[Other people's assets]
  I --> F[Client flow]
  I --> C[Own capital]
  I --> S[Selling services]
  P --> G[Asset managers and funds]
  F --> B[Brokers and banks]
  C --> T[Prop and market makers]
  S --> D[Fintech and data]
```

- **Other people's assets.** The firm manages other people's money and charges a percentage on it (management fee)
  and, sometimes, on the return (performance fee). Its revenue grows with the assets and with the ability to retain
  them.
- **Client flow.** The firm charges for executing, holding in custody, financing or distributing: per-order
  commissions, interest margin on cash and securities lending, retrocessions for distributing funds.
- **Own capital.** The firm puts its balance sheet at risk. It earns if its statistical edge exceeds the costs and the
  inventory risk; nobody pays it for trying.
- **Selling services.** Data subscriptions, software, platforms or analysis. The client pays even if they lose money in
  the market.

A large firm combines several of these; an investment bank has all four. But each desk or each subsidiary usually
lives off one, and it is worth knowing which before the interview (lesson 7.5.3).

## Seven types of firm

| Type | What it does | Where the revenue comes from | Typical quantitative work | Lessons and modules |
|---|---|---|---|---|
| Hedge fund | Strategies with leverage, short selling and derivatives for professional investors | Management and performance fees on assets | Signal research, portfolios, execution, risk | 2.2, 2.5, 4.1, level 5 |
| Proprietary trading | Trades only its own capital, without clients | The result of its positions | Short-term strategies, latency, intraday risk control | 2.3, 4.2.5, 4.3, 7.1.2 |
| Bank (markets) | Market making for clients, structuring, hedging, financing | Bid-ask spread, fees, interest margin | Derivatives valuation, XVA, risk models, execution | 3.4, 4.2, 4.3.1 |
| Asset manager | Investment funds and portfolios, mostly long-only and benchmarked | Fee on assets | Portfolio construction, factors, attribution, risk control | 4.1, 2.6, 5.5.6 |
| Market maker | Quotes bids and offers continuously | Bid-ask spread minus adverse selection; venue incentives | Microstructure, inventory, latency, infrastructure | 2.3.6, 4.3.2, 7.1 |
| Crypto | Exchanges, custodians, market makers and funds on crypto-assets | Trading fees, funding, bid-ask spread | Counterparty risk, arbitrage, on-chain data | 1.2.6, 3.7, 4.4.4 |
| Fintech | Online brokers, automated investing, data and software | Fees, interest on cash, subscriptions | Data engineering, product, MLOps, compliance | 1.3, 7.2, 7.3 |

Two nuances the table does not capture. The first: “hedge fund” is not a European legal form. In the EU, whoever
manages strategies of that kind is an alternative investment fund manager (AIFM; GFIA in Spanish) and, in Spain, it can
also be an SGIIC that manages hedge-fund-type IICs (*IIC de inversión libre*). The second: “prop firm” designates two
things that are nothing alike. One is a proprietary trading firm, with its own capital and employees. The other sells
retail customers evaluations in simulated accounts and promises them capital if they pass; its model and its risks are
studied in lesson 7.5.4.

<aside class="callout" data-kind="nota">

Trading on own account does not always require authorization. Article 2(1)(d) of MiFID II, in its original wording,
exempts those who deal on own account in financial instruments other than commodity derivatives and provide no other
investment services, **unless** they are market makers, members or participants of a regulated market or an MTF or have
direct electronic access to a trading venue, apply a high-frequency algorithmic trading technique, or deal on own
account when executing client orders. The proprietary trading firms that hire quants usually fall into one of those
exceptions and are authorized. This is not legal advice.

</aside>

## Legal forms in Spain

Each type of firm has a license, and the license says what it can do. Article 128 of Spain's Law 6/2023 on Securities
Markets classifies Spanish investment firms (*empresas de servicios de inversión*, ESI):

- **Sociedades de valores (SV, securities firms).** They may operate “both on behalf of others and on their own
  account” and provide all investment services. It is the legal form of a broker that also trades with its balance
  sheet or makes markets.
- **Agencias de valores (AV, securities agencies).** They “may only operate on behalf of others”. They receive,
  transmit and execute client orders, manage portfolios or advise, but they do not trade on their own account.
- **Sociedades gestoras de carteras (SGC, portfolio management companies)** and **empresas de asesoramiento
  financiero (EAF, financial advisory firms).** Discretionary portfolio management and advice, without being able to
  hold client funds or securities.
- **Credit institutions.** They are not ESIs, but the same article allows them to provide all investment services if
  their authorization covers them. That is why a bank can have a trading desk.

The quotations from Law 6/2023 are an unofficial translation. Outside that article are the **SGIICs**, which manage
investment funds and companies (IIC, *instituciones de inversión colectiva*, including hedge-fund-type ones), the
**SGEICs**, which manage closed-ended investment entities (private equity and venture capital), and the crypto-asset
service providers (CASPs) authorized under MiCA, which are studied in lesson 3.7.5.

## The Spanish ecosystem in the CNMV lists

The CNMV publishes one list per type of entity, an HTML page with one block per entity: name, registration number and
date, and address. Lesson 4.4.1 already read the list of European investment firms operating under the freedom to
provide services to check a broker; here the others are used to measure the ecosystem. The lists are in Spanish, and
the code reads them as they are. The real code that downloads and counts them:

```python skip title="cnmv_listas.py"
import html
import re
from urllib.request import Request, urlopen

BASE = "https://www.cnmv.es/portal/consultas/listadoentidad.aspx"
LISTAS = {"SV and AV": "?id=1&tipoent=0", "EAF": "?id=1&tipoent=2",
          "SGIIC": "?id=2&tipoent=0", "SGEIC": "?id=4&tipoent=0"}
for tipo, q in LISTAS.items():
    req = Request(BASE + q, headers={"User-Agent": "Mozilla/5.0"})
    with urlopen(req, timeout=30) as r:
        pagina = r.read().decode("utf-8", errors="replace")
    texto = html.unescape(re.sub(r"<[^>]+>", "\n", pagina))
    # "Official registration number and date", one per entity
    n = texto.count("Número y fecha de registro oficial")
    print(tipo, n)
```

On October 23, 2026 it printed 114 SV and AV, 92 EAF, 122 SGIIC and 165 SGEIC. The list of Spanish credit institutions
uses another format (a code of the Banco de España, Spain's central bank, instead of a registration number) and had
102. The next cell processes a **fictitious** extract with the format of the lists (with less indentation), in Spanish
like the original, to work without a network connection:

```python
import re
import pandas as pd

LISTA = """
ALCOR MERCADOS, SOCIEDAD DE VALORES, S.A.
  Número y fecha de registro oficial: 901 - 12/03/1990
    Dirección: C/ MAYOR 1 - 28013 MADRID
BRIO PATRIMONIOS, A.V., S.L.
  Número y fecha de registro oficial: 902 - 02/06/2017
    Dirección: C/ ARAGO 2 - 08007 BARCELONA
CENIT GESTION, SGIIC, S.A.
  Número y fecha de registro oficial: 903 - 10/04/2001
    Dirección: GRAN VIA 3 - 48001 BILBAO
DUNA CAPITAL PRIVADO, SGEIC, S.A.
  Número y fecha de registro oficial: 904 - 01/09/2026
    Dirección: C/ COLON 4 - 46004 VALENCIA
EBRO ASESORES EAF, S.L.
  Número y fecha de registro oficial: 905 - 15/01/2025
    Dirección: C/ ALFONSO I 5 - 50003 ZARAGOZA
FARO QUANT A.V, S.L.
  Número y fecha de registro oficial: 906 - 24/07/2026
    Dirección: C/ AZOR 6 - 28691 VILLANUEVA
"""
patron = re.compile(
    r"^(?P<nombre>\S[^\n]*)\n"
    r"\s*Número y fecha de registro oficial: (?P<num>\d+)"
    r" - (?P<fecha>\d\d/\d\d/\d{4})\n"
    r"\s*Dirección: (?P<direccion>[^\n]*)", re.M)
ent = pd.DataFrame([m.groupdict() for m in patron.finditer(LISTA)])
ent["fecha"] = pd.to_datetime(ent["fecha"], format="%d/%m/%Y")
ent["cp"] = ent["direccion"].str.extract(r"- (\d{5})\b")[0]
ent[["nombre", "num", "fecha", "cp"]]
```
```output
                                      nombre  num      fecha     cp
0  ALCOR MERCADOS, SOCIEDAD DE VALORES, S.A.  901 1990-03-12  28013
1               BRIO PATRIMONIOS, A.V., S.L.  902 2017-06-02  08007
2                 CENIT GESTION, SGIIC, S.A.  903 2001-04-10  48001
3          DUNA CAPITAL PRIVADO, SGEIC, S.A.  904 2026-09-01  46004
4                    EBRO ASESORES EAF, S.L.  905 2025-01-15  50003
5                       FARO QUANT A.V, S.L.  906 2026-07-24  28691
```

The columns are the name, the registration number, the date and the postal code (`cp`). The list mixes sociedades and
agencias de valores, and the legal form of each one is only in the name, written without a fixed rule: “SOCIEDAD DE
VALORES”, “S.V.”, “A.V.”, “AV” or, as in a real entity on the list, “A.V,” with the comma attached. Management
companies write “SGIIC” or “S.G.I.I.C.”, and EAFs, “EAF” or “EAFI”. A classifier based on regular expressions has to
accept those variants. The province comes from the first two digits of the postal code:

```python
REGLAS = [
    ("SV", r"SOCIEDAD DE VALORES|\bS\.?V\b"),
    ("AV", r"AGENCIA DE VALORES|\bA\.?V\b"),
    ("SGIIC", r"\bS\.?G\.?I\.?I\.?C\b|GESTORA DE INSTITUCIONES"),
    ("SGEIC", r"\bS\.?G\.?E\.?I\.?C\b|ENTIDADES DE INVERSI[OÓ]N"),
    ("EAF", r"\bE\.?A\.?F\.?I?\b|ASESORAMIENTO FINANCIERO"),
]
PROVINCIAS = {"28": "Madrid", "08": "Barcelona", "48": "Bizkaia",
              "46": "Valencia", "50": "Zaragoza"}

def tipo(nombre: str) -> str:
    for etiqueta, regla in REGLAS:
        if re.search(regla, nombre.upper()):
            return etiqueta
    return "unclassified"

ent["tipo"] = ent["nombre"].map(tipo)
ent["provincia"] = ent["cp"].str[:2].map(PROVINCIAS).fillna("other")
ent[["nombre", "tipo", "provincia"]]
```
```output
                                      nombre   tipo  provincia
0  ALCOR MERCADOS, SOCIEDAD DE VALORES, S.A.     SV     Madrid
1               BRIO PATRIMONIOS, A.V., S.L.     AV  Barcelona
2                 CENIT GESTION, SGIIC, S.A.  SGIIC    Bizkaia
3          DUNA CAPITAL PRIVADO, SGEIC, S.A.  SGEIC   Valencia
4                    EBRO ASESORES EAF, S.L.    EAF   Zaragoza
5                       FARO QUANT A.V, S.L.     AV     Madrid
```

With the real lists, that classifier assigns a type to each of the 493 entities on the four lists and splits the 114 on
the first one into 40 sociedades and 74 agencias de valores: they are the two bottom bars of the header figure. The
sociedades de valores, highlighted, are the only Spanish investment firms that may trade on their own account. The same
aggregation gives the geography:

```python
# (entities with postal code 28xxx, total of the list)
madrid = pd.DataFrame(
    {"en_madrid": [88, 101, 96, 53], "total": [114, 122, 165, 92]},
    index=["SV and AV", "SGIIC", "SGEIC", "EAF"])
madrid["pct"] = (100 * madrid["en_madrid"] / madrid["total"]).round(1)
madrid
```
```output
           en_madrid  total   pct
SV and AV         88    114  77.2
SGIIC            101    122  82.8
SGEIC             96    165  58.2
EAF               53     92  57.6
```

More than three quarters of the SVs and AVs and of the SGIICs have their registered address in the province of Madrid;
the private equity management companies (SGEICs) and the EAFs are somewhat more spread out, with Barcelona in second
place (35 SGEICs and 14 EAFs). The registered address is the registered office: it does not say where each employee
works, but it does say where the management and, almost always, the desks are.

<aside class="callout" data-kind="aviso">

The lists only contain the entities currently **registered**. That there are 43 SGIICs registered before 2000 and
between 2 and 10 in each year since 2015 does not mean that more management companies used to be created: those that
were deregistered do not appear. It is the survivorship bias of lesson 1.4.4 in a register. To study registrations and
deregistrations you have to use historical series.

</aside>

## How they make money, with CNMV data

The CNMV investment firm statistics publish every quarter the aggregate balance sheet and income statement of
sociedades and agencias de valores. Table 1.4 breaks down the fees received by service, in thousands of euros
**accumulated since the start of the year** (note 2 of the table), so the fourth quarter column is the full year. This
is the 2025 extract, with the figures from the table published with data up to June 2026. The items keep the CNMV's
Spanish wording; the top ones are the distribution of IIC (investment funds), order handling and execution, “other”,
investment advice and portfolio management:

```python
import io

CUADRO = """partida;miles
2.1.1. Tramitación y ejecución de órdenes;170.106
2.1.2. Colocación y aseguramiento de emisiones;10.296
2.1.3. Depósito y anotación de valores;32.196
2.1.4. Gestión de carteras;68.167
2.1.5. Asesoramiento en materia de inversión;68.920
2.1.6. Búsqueda y colocación de paquetes;1.147
2.1.7. Operaciones de crédito al mercado;0
2.1.8. Comercialización de IIC;232.984
2.1.9. Internalización sistemática de órdenes;0
2.1.10. Intermediación en instrumentos derivados;11.279
2.1.11. Elaboración de informes y análisis financieros;11.077
2.1.12. Servicios y actividades con criptoactivos;0
2.1.13. Otras;106.013
"""
com = pd.read_csv(io.StringIO(CUADRO), sep=";", thousands=".")
com[["codigo", "servicio"]] = com["partida"].str.extract(
    r"^([\d.]+?)\.? (.+)$")
total = com["miles"].sum()
print(f"Sum: {total} thousand euros; table total: 712186")
com["pct"] = (100 * com["miles"] / total).round(1)
print(com.sort_values("miles", ascending=False)[
    ["servicio", "miles", "pct"]].head(5).to_string(index=False))
```
```output
Sum: 712185 thousand euros; table total: 712186
                             servicio  miles  pct
              Comercialización de IIC 232984 32.7
   Tramitación y ejecución de órdenes 170106 23.9
                                Otras 106013 14.9
Asesoramiento en materia de inversión  68920  9.7
                  Gestión de carteras  68167  9.6
```

*Fig. — Fees and commissions received by Spanish broker-dealers and broker agencies in 2025, by service.* Horizontal bars in millions of euros: distribution of investment funds 233.0 (highlighted), order handling and execution 170.1, other 106.0, investment advice 68.9, portfolio management 68.2, custody 32.2, derivatives 11.3, research 11.1 and underwriting and placement 10.3.

The sum of the items falls one thousand euros short of the published total: each item is rounded to thousands, and a
difference of one unit is rounding, not a transcription error. Checking the sum is the first thing to do when copying a
table. And the result contradicts the usual image of a broker: the top item is not order execution but **fund
distribution**, a third of the fees. Execution, brokerage in derivatives and block trade sourcing, the closest thing to
trading, add up to 25.6%. For a job seeker this has a direct reading: in many Spanish investment firms the business is
distributing and advising, and the quantitative work, when there is any, is in portfolios, risk and data rather than in
strategies.

The income statement also says how much staff costs weigh:

```python
pyg = pd.Series({"margen_bruto": 649_333, "personal": 309_801,
                 "generales": 166_567, "antes_impuestos": 162_612})
print((pyg / 1000).round(1).to_string())
print(f"Staff costs / gross margin: "
      f"{pyg['personal'] / pyg['margen_bruto']:.1%}")
```
```output
margen_bruto       649.3
personal           309.8
generales          166.6
antes_impuestos    162.6
Staff costs / gross margin: 47.7%
```

The keys are the gross margin, staff costs, general expenses and profit before tax, in millions of euros. Staff costs
were the sector's largest expense in 2025, almost half of the gross margin. It is an aggregate figure for 114 very
different entities and says nothing about individual salaries: the statistics do not publish them and this lesson gives
no salary figures without a primary source that publishes them.

## Europe in the ESMA register

ESMA (the European Securities and Markets Authority) maintains a register of entities authorized under MiFID II and
other rules (UCITS and alternative fund managers, trading venues, systematic internalisers). The web interface queries
a Solr index that supports counts by field (*facets*). The query below worked on October 23, 2026; it is not a
documented API:

```python skip title="esma_recuentos.py"
import json
from urllib.parse import urlencode
from urllib.request import Request, urlopen

URL = ("https://registers.esma.europa.eu/solr/"
       "esma_registers_upreg/select?")
params = [("q", "type_s:parent"), ("rows", 0), ("wt", "json"),
          ("fq", "ae_status:Active"),
          ("fq", 'ae_officeType:"Head office"'),
          ("facet", "true"), ("facet.limit", 60),
          ("facet.pivot", "ae_entityTypeLabel,ae_homeMemberState")]
req = Request(URL + urlencode(params),
              headers={"User-Agent": "Mozilla/5.0"})
with urlopen(req, timeout=30) as r:
    datos = json.load(r)
pivote = datos["facet_counts"]["facet_pivot"]
print(pivote["ae_entityTypeLabel,ae_homeMemberState"][0])
```

The response is a tree: one node per entity type with its total and, inside, one node per home Member State. The next
cell reads an extract of that response with the **real values** of the query (the top five States of each type and
Spain):

```python
import json

RESPUESTA = """[
 {"value": "investment firm", "count": 5319, "pivot": [
  {"value": "germany", "count": 1865}, {"value": "italy", "count": 463},
  {"value": "austria", "count": 458}, {"value": "spain", "count": 312},
  {"value": "france", "count": 268}]},
 {"value": "aifm", "count": 2882, "pivot": [
  {"value": "france", "count": 566}, {"value": "poland", "count": 384},
  {"value": "spain", "count": 337}, {"value": "luxembourg",
  "count": 273}, {"value": "hungary", "count": 137}]},
 {"value": "ucits management company", "count": 1143, "pivot": [
  {"value": "luxembourg", "count": 286}, {"value": "france",
  "count": 224}, {"value": "spain", "count": 110},
  {"value": "ireland", "count": 92}, {"value": "italy", "count": 45}]}
]"""
filas = [{"tipo": t["value"], "total": t["count"],
          "estado": e["value"], "n": e["count"]}
         for t in json.loads(RESPUESTA) for e in t["pivot"]]
esma = pd.DataFrame(filas)
esma["pct"] = (100 * esma["n"] / esma["total"]).round(1)
print(esma[esma["estado"] == "spain"].to_string(index=False))
```
```output
                    tipo  total estado   n  pct
         investment firm   5319  spain 312  5.9
                    aifm   2882  spain 337 11.7
ucits management company   1143  spain 110  9.6
```

*Fig. — Active investment firms in the ESMA register, by home Member State (top eight; 23 October 2026).* Horizontal bars: Germany 1,865, Italy 463, Austria 458, Spain 312 (highlighted), France 268, Cyprus 265, Netherlands 222 and Denmark 199.

Spain is the fourth State by number of active investment firms and the third in alternative and UCITS fund managers.
But the ESMA and CNMV counts do not count the same thing: the register's 312 Spanish “investment firms” are almost
three times the 114 SVs and AVs on the national list. Classifying the 312 names with the lesson's rules yields 39 SVs,
75 AVs, 92 EAFs and 106 names without any of those abbreviations; 103 of them have “BANCO”, “BANK”, “CAJA”, “CAIXA”
or “CRÉDITO” in their name. Credit institutions that provide investment services (Article 128(3) of Law 6/2023) appear
in the European register under that label, and the CNMV lists them separately. Comparing countries with this count
requires knowing which national legal forms each authority loads under the same label: a count without a definition is
useless for comparison.

## From the register to the job posting

With the map and the sources, checking a potential employer takes a few minutes and avoids surprises:

```mermaid
flowchart LR
  A[Job posting] --> R{In a register?}
  R -- yes --> L{Matching license?}
  R -- no --> W[Warnings]
  L -- yes --> E[Interview]
  L -- no --> P[Ask]
```

1. **Identify the entity that is hiring.** The trade name is not enough: the contract is signed with a company, and the
   legal notice on its website gives the company name and the registration number.
2. **Look it up in the register that matches what it says it does.** Fund management: SGIIC or SGEIC at the CNMV, or
   UCITS management company or AIFM in the ESMA register. Proprietary trading or market making: SV or credit
   institution. Crypto-assets: authorized CASP (lesson 3.7.5).
3. **Check that the license matches the activity.** An agencia de valores that advertises a proprietary trading desk,
   or an EAF that talks about “managing the firm's capital”, deserves a question in the interview.
4. **If it does not appear in any register**, look it up in the CNMV warnings about unauthorized entities. Not
   appearing in a register is not illegal if the activity does not require authorization (a software company, a
   consultancy, a trader with their own money), but then it is not a regulated financial entity, with what that implies
   for job stability and for what it can promise.

The step from each type of firm to a specific position, and what is asked in interviews, is in lesson 7.5.3; the
training that job postings ask for and the risks of evaluation prop firms, in 7.5.4.

<aside class="callout" data-kind="nota">

This lesson describes sectors and registers with primary sources accessed on October 23, 2026. It recommends no firms
and rates none, and the figures in the registers change daily: between October 22 and 23 the list of European
investment firms operating under the freedom to provide services went from 809 to 811 entities.

</aside>

## Exercises

1. Classify these names, in the format of the ESMA register, with the lesson's `tipo` function extended with a rule for
   credit institutions. How many fall into each group?

**Solution.**

```python
NOMBRES = ["ALCOR MERCADOS, SOCIEDAD DE VALORES, S.A.",
           "BRIO PATRIMONIOS, A.V., S.L.", "CENIT BANCO, S.A.",
           "CAJA RURAL DEL EBRO, S. COOP. DE CREDITO",
           "EBRO ASESORES EAF, S.L.", "GALENA INVESTMENT, S.A."]
REGLAS_ESMA = REGLAS + [
    ("credit", r"BANC|BANK|\bCAJA\b|CAIXA|CR[EÉ]DITO")]

def tipo_esma(nombre: str) -> str:
    for etiqueta, regla in REGLAS_ESMA:
        if re.search(regla, nombre.upper()):
            return etiqueta
    return "unclassified"

pd.Series([tipo_esma(n) for n in NOMBRES]).value_counts()
```
```output
credit          2
SV              1
AV              1
EAF             1
unclassified    1
Name: count, dtype: int64
```

The order of the rules matters: the investment firm abbreviations go before the credit ones so that “… BANCA, AGENCIA
DE VALORES” is not counted as a bank. GALENA INVESTMENT stays unclassified, like three real names in the ESMA register;
one is “SANTANDER INVESTMENT, S.A.”, which appears on the CNMV list of Spanish credit institutions even though its name
does not say so. For those cases the name is not enough and you have to cross-check with that list or with the Banco de
España code.

2. The figures in table 1.4 are accumulated since January. With the fees for order handling and execution accumulated
   to June, September and December 2025 (84,337, 124,996 and 170,106 thousand euros) and to March and June 2026 (51,838
   and 97,771), compute those of each quarter. Which quarter had the most order fees?

**Solution.**

```python
acum = pd.Series([84_337, 124_996, 170_106, 51_838, 97_771],
                 index=["2025Q2", "2025Q3", "2025Q4",
                        "2026Q1", "2026Q2"])
anio = acum.index.str[:4]
trim = acum.groupby(anio).diff().fillna(acum)
trim = trim.drop("2025Q2")  # without 2025Q1 it cannot be separated
trim.astype(int)
```
```output
2025Q3    40659
2025Q4    45110
2026Q1    51838
2026Q2    45933
dtype: int64
```

The first quarter of each year is already quarterly; the others are obtained by subtracting the previous accumulated
figure **of the same year**, which is why the difference is grouped by year. The 2025Q2 figure cannot be separated
without the one for March 2025, which is not in the extract. The quarter with the most order fees was the first of
2026, with 51,838 thousand euros, against 40,000–46,000 in the others. Subtracting without grouping would have given a
negative “2026Q1” (51,838 − 170,106), a classic error when working with accumulated income statements.

3. A job posting asks for a “quant researcher” for “a proprietary trading firm based in Madrid” and does not give the
   company name. List what you would check before and during the interview with the sources of this lesson.

**Solution.**

Before: the company name (legal notice on the website or the Spanish companies register) and its presence on the CNMV
list of sociedades de valores or in the ESMA register as an investment firm or credit institution; if it trades only
its own capital and without access as a member, it may not need authorization (Article 2(1)(d) of MiFID II), and then
it is worth knowing. If it does not appear in any register, the CNMV warnings. During the interview: where the revenue
comes from (own capital of partners, of a group or of third parties), who bears the losses, on which markets it is a
member or with which brokers it trades, how intraday risk is controlled (lesson 4.2.5) and how a researcher's work is
measured. If “own capital” turns out to be that of customers who pay for evaluations, it is the model of lesson 7.5.4,
not a proprietary trading firm.

## Self-assessment

1. A Spanish firm advertises a “quantitative trader” position to trade its own capital on a regulated market of which it is a member. Which legal form under Spain's Law 6/2023 fits that activity?

   - A. An agencia de valores (securities agency)
   - B. A sociedad de valores (securities firm), or a credit institution authorized to do so
   - C. A financial advisory firm (EAF)
   - D. A portfolio management company (SGC)

   *Answer B: A sociedad de valores (securities firm), or a credit institution authorized to do so.* Article 128 of Law 6/2023 allows sociedades de valores to operate both on behalf of others and on their own account. Agencias de valores may only operate on behalf of others, and SGCs and EAFs may not operate in their own name except to manage their own assets. Credit institutions may provide investment services if their authorization covers them.

2. In 2025, what was the largest source of fee income of Spanish sociedades and agencias de valores according to CNMV table 1.4?

   - A. Order handling and execution
   - B. Brokerage in derivatives
   - C. Portfolio management
   - D. Distribution of IIC (investment funds)

   *Answer D: Distribution of IIC (investment funds).* Distribution of IIC added up to €233.0 million, 32.7% of the fees received, ahead of order handling and execution (€170.1 million, 23.9%). The business of many Spanish investment firms depends more on client assets than on traded volume.

3. The ESMA register counts 312 active “investment firms” with their head office in Spain, and the CNMV lists 114 sociedades and agencias de valores and 92 EAFs. Where does the difference come from?

   - A. From credit institutions that provide investment services and appear in the ESMA register under that label
   - B. From an error in the ESMA register
   - C. From branches of foreign firms
   - D. From deregistered firms that ESMA has not removed

   *Answer A: From credit institutions that provide investment services and appear in the ESMA register under that label.* Classifying the 312 names, 39 are SVs, 75 AVs, 92 EAFs and 106 carry none of those abbreviations: judging by the name, almost all of them banks, savings banks and credit cooperatives. The query already filters active entities and head offices. Before comparing two registers you have to read what each one counts.

4. The CNMV list of SGIICs shows many more management companies registered before 2000 than in any recent year. What can be concluded?

   - A. That more management companies used to be created
   - B. That the sector is in decline
   - C. Nothing about registrations per year: the list only contains the management companies currently registered, so it measures survivors, not entries
   - D. That older management companies are better

   *Answer C: Nothing about registrations per year: the list only contains the management companies currently registered, so it measures survivors, not entries.* It is the survivorship bias of lesson 1.4.4 applied to a register: the management companies that were deregistered do not appear. To study entries and exits you need historical series, such as those in the CNMV statistics.

5. What distinguishes the revenue model of a market maker from that of an asset manager?

   - A. No difference: both charge management fees
   - B. The market maker earns the bid-ask spread with its own balance sheet and loses against better informed counterparties; the asset manager charges a fee on its clients' assets
   - C. The asset manager earns the bid-ask spread and the market maker charges a performance fee
   - D. Both live off selling data

   *Answer B: The market maker earns the bid-ask spread with its own balance sheet and loses against better informed counterparties; the asset manager charges a fee on its clients' assets.* They are the two ends of the map: own capital and inventory risk (lesson 2.3.6) versus other people's assets and fees. That is why they change the type of quantitative work, the tolerance for latency and the way performance is measured.

## Key points

- The type of firm is understood by the source of its revenue: other people's assets (asset managers, hedge funds), client flow (brokers, banks, exchanges), own capital (proprietary trading, market makers) or selling services (fintech, data).
- In Spain, only sociedades de valores and authorized credit institutions may trade on their own account; agencias de valores operate on behalf of others (Article 128 of Law 6/2023).
- The CNMV lists of October 23, 2026 have 40 SVs, 74 AVs, 92 EAFs, 122 SGIICs, 165 SGEICs and 102 credit institutions; more than three quarters of the SVs and AVs and of the SGIICs have their address in Madrid.
- In 2025 the SVs and AVs received €712.2 million in fees, and the top item was fund distribution (32.7%); staff costs were 47.7% of the gross margin.
- The ESMA register counts 5,319 active investment firms in the EEA; the 312 Spanish ones include banks that provide investment services.
- Registers count survivors and each one defines in its own way what counts: before drawing conclusions, read the definition and the date.

## Resources

### Research

- [Quant research](https://pythonparatrading.com/en/quant-research-2/) · Research-0023 · 8 min

### Documentation

- [CNMV (Spanish securities regulator): lists of registered entities (SV and AV, SGIIC, EAF, foreign investment firms, credit institutions; in Spanish)](https://www.cnmv.es/portal/consultas/listadoentidad.aspx?id=1&tipoent=0) · cnmv.es
- [CNMV: statistics on investment firms (quarterly balance sheets and income statements; in Spanish)](https://www.cnmv.es/portal/publicaciones/consultasestadisticas.aspx?id=ESI) · cnmv.es
- [ESMA: databases and registers](https://www.esma.europa.eu/publications-and-data/databases-and-registers) · esma.europa.eu
- [BOE (Spain's official gazette): Law 6/2023 of March 17 on Securities Markets and Investment Services (Article 128; in Spanish)](https://www.boe.es/buscar/act.php?id=BOE-A-2023-7053) · boe.es
- [Directive 2014/65/EU (MiFID II), text published in the Official Journal of the EU (Article 2: exemptions; Spanish-language edition)](https://boe.es/doue/2014/173/L00349-00496.pdf) · boe.es

Previous lesson: [7.5.1 · Quant roles: six jobs around the same system](https://pythonparatrading.com/en/python-trading-course/level-7/quant-roles-explained/)

Next lesson: [7.5.3 · Public portfolio and interviews: show judgment, not returns](https://pythonparatrading.com/en/python-trading-course/level-7/quant-portfolio-and-interviews/)
