Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
I
inventario
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jose Luis Gordillo Ruiz
inventario
Commits
de9df8cb
Commit
de9df8cb
authored
Jan 21, 2025
by
Jose Luis Gordillo Ruiz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
primera versión de un scatter de IMC vs algunos químicos
parent
2e9e4352
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
0 deletions
+29
-0
estadisticas.py
+29
-0
No files found.
estadisticas.py
View file @
de9df8cb
...
...
@@ -51,6 +51,29 @@ def popdist(datos):
)
return
fig
def
popcorr
(
datos
):
medidas
=
[
"glucose"
,
"hba1c"
,
"ct"
,
"hdl"
,
"insuline"
]
# removemos outliers
fig
=
make_subplots
(
rows
=
2
,
cols
=
3
,
shared_yaxes
=
False
,
subplot_titles
=
medidas
)
lcol
=
1
lrow
=
1
for
medida
in
medidas
:
datosfil
=
datos
[
np
.
abs
(
stats
.
zscore
(
datos
[
medida
],
nan_policy
=
'omit'
))
<
3
]
fig
.
add_trace
(
go
.
Scatter
(
x
=
datosfil
[
"imc"
],
y
=
datosfil
[
medida
],
name
=
medida
,
mode
=
"markers"
),
row
=
lrow
,
col
=
lcol
)
lrow
=
lrow
+
(
lcol
//
3
)
lcol
=
lcol
+
1
if
lcol
<
3
else
1
fig
.
update_layout
(
bargap
=
0.05
,
# gap between bars of adjacent location coordinates
bargroupgap
=
0.05
,
# gap between bars of the same location coordinates
showlegend
=
False
)
return
fig
def
correlaciones
(
datos
,
controlado
):
...
...
@@ -445,6 +468,12 @@ app.layout = html.Div(children=[
html
.
Div
(
children
=
[
html
.
H1
(
"Distribuciones de la población"
,
className
=
"header-title2"
),],
),
dcc
.
Graph
(
figure
=
popdist
(
visitas_incluidos
))
]),
# correlaciones entre indices de la poblacion
html
.
Div
(
children
=
[
html
.
Div
(
children
=
[
html
.
H1
(
"Correlaciones entre medidas"
,
className
=
"header-title2"
),],
),
dcc
.
Graph
(
figure
=
popcorr
(
visitas_incluidos
))
]),
# ppgr a controlados
html
.
Div
(
children
=
[
html
.
Div
(
children
=
[
html
.
H1
(
"iAUC/Controlados "
,
className
=
"header-title2"
)]),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment