---
name: scatter_plot
kind: component
lang: cpp
domain: viz
version: "1.1.0"
purity: pure
signature: "void scatter_plot(const char* title, const float* xs, const float* ys, int count, float height = 200.0f)"
description: "Scatter plot 2D con ImPlot, ejes pineados y altura explicita para no vibrar al redimensionar"
tags: [implot, chart, visualization, gpu, scatter, locked-axes]
uses_functions: ["plot_static_cpp_viz"]
uses_types: []
returns: []
returns_optional: false
error_type: ""
imports: [implot]
tested: false
tests: []
test_file_path: ""
file_path: "cpp/functions/viz/scatter_plot.cpp"
framework: imgui
params:
  - name: title
    desc: "Titulo del grafico / id interno"
  - name: xs
    desc: "Array de coordenadas X"
  - name: ys
    desc: "Array de coordenadas Y"
  - name: count
    desc: "Numero de puntos en los arrays xs/ys"
  - name: height
    desc: "Altura del plot en pixeles (default 200). Explicita para evitar feedback loops"
output: "Renderiza el scatter en el frame ImGui actual con ejes pineados"
notes: "consumido por cpp/apps/chart_demo/main.cpp; scaffolding/demo en primitives_gallery"
---

# scatter_plot

Wrapper atomico sobre `ImPlot::PlotScatter` configurado para visualizacion estatica.

## v1.1

- **Altura explicita** (`height`).
- **Ejes pineados** (`plot_static::kAxisFlags` + `ImPlotCond_Always`) calculados a partir de min/max de `xs`/`ys` con 5% de headroom en ambos ejes.
- **Sin inputs, sin auto-fit** — ver `viz/plot_static.h`.

Soporta `float` y `double`.
