feat(tea): intervalo de análisis, resumen más preciso y alteraciones del EEG
- Filtro general: «Intervalo de análisis» (Semestral/Mensual) en lugar de «Modalidad»; al cambiar de intervalo se elige el periodo más reciente. - Resumen de TEA: evaluaciones con o sin diagnóstico y diagnóstico positivo de TEA explícito. - Seguimiento: panel «Alteraciones del EEG» (exponente aperiódico, husos del sueño, entropía multiescala) con posibles efectos asociados. Datos de ejemplo, pendientes de validación médica. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -2,12 +2,13 @@ import { Component, DestroyRef, inject, Input, OnInit, signal } from '@angular/c
|
||||
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
||||
import { PlotlyChart } from '../../shared/plotly/plotly-chart';
|
||||
import { PlotlyFigure } from './indicadores.models';
|
||||
import { TeaAdos2, TeaEeg, TeaPacienteDetalle, TeaSeguimientoService } from './tea-seguimiento.service';
|
||||
import { TeaAdos2, TeaAlteracionEstado, TeaEeg, TeaPacienteDetalle, TeaSeguimientoService } from './tea-seguimiento.service';
|
||||
|
||||
const CLASIFICACION: Record<TeaAdos2['clasificacion'], string> = { autismo: 'Autismo', espectro_autista: 'Espectro autista', no_espectro: 'No espectro' };
|
||||
// ADOS-2 calibrated severity score ranges.
|
||||
const NIVEL_CSS: Record<TeaAdos2['nivel_css'], string> = { minimo: 'Evidencia mínima o nula', bajo: 'Nivel bajo', moderado: 'Nivel moderado', alto: 'Nivel alto' };
|
||||
const CALIDAD: Record<TeaEeg['calidad'], string> = { buena: 'Buena', aceptable: 'Aceptable', deficiente: 'Deficiente' };
|
||||
const ESTADO: Record<TeaAlteracionEstado, string> = { normal: 'Dentro de referencia', aumentado: 'Aumentado', disminuido: 'Disminuido', no_evaluable: 'No evaluable' };
|
||||
const INK = '#081839';
|
||||
|
||||
// Shape paths have no arcs: the hole is a polygon, wound against the frame so it stays empty under either fill rule.
|
||||
@@ -58,6 +59,7 @@ export class TeaPacienteResumen implements OnInit {
|
||||
readonly clasificacion = CLASIFICACION;
|
||||
readonly nivelCss = NIVEL_CSS;
|
||||
readonly calidad = CALIDAD;
|
||||
readonly estado = ESTADO;
|
||||
ngOnInit() { this.load(); }
|
||||
load() {
|
||||
this.status.set('loading');
|
||||
@@ -66,5 +68,6 @@ export class TeaPacienteResumen implements OnInit {
|
||||
error: () => this.status.set('error'),
|
||||
});
|
||||
}
|
||||
alteradas(eeg: TeaEeg) { return eeg.alteraciones.filter(m => m.estado === 'aumentado' || m.estado === 'disminuido'); }
|
||||
pct(value: number, max: number) { return max > 0 ? Math.round(100 * value / max) : 0; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user