Forum Discussion
Create line chart with 2 y-axes
Hi all!
I am stuggling with a visual I would like to create.
My table looks as follows (a bit simplified though)
| patient ID | admission date | discharge date | length of stay | 30d readmission |
| 1 | 1 jan 2017 | 10 jan 2017 | 9 days | yes |
| 1 | 5 march 2018 | 6 march 2018 | 1 day | no |
| 2 | 5 feb 2018 | 10 feb 2018 | 5 days | yes |
| 2 | 12 june 2018 | 20 june 2018 | 8 days | no |
| 2 | 10 sep 2018 | 30 sep 2018 | 20 days | no |
So I have multiple hospital admissions per patient, for which I have the length of stay.
Not all hospital admission are 30d readmission (i.e. an admission within 30 days after an index event).
Now I want to create a visual showing:
- 1 line with average length of stay per year (2017 - 2018 - 2019 - etc.). Here, all hospitalisations within that year can be included in the calculation of the average.
- 1 line with number of patients / % of patients that have had a 30d readmission.
Is it possible to combine these 2?
im_92 , In line visual you can secondary y-axis and have lines on two axis
1 Reply
- amitchandak
Super User
im_92 , In line visual you can secondary y-axis and have lines on two axis