Heart Rate Graph Shortcut

New to the forum, hoping this isn’t a repeat.

I have updated, modified, and split a shortcut built originally by Cranie in a Reddit forum.

The purpose of the shortcut is to create a graph of my heart rate and heart rate variability over the past week, and combine them into one image. I then place in my weekly journal. This is by using the Google Charts gstatic javascript. There were a few annoyances I had to deal with, including the fact that Google Charts uses 0 for January. Obviously this shortcut pulls a lot of data in its loop, and can take a while even at 7 days of data.

I haven’t found a way to combine the two onto one axis yet, as the heart rate variability doesn’t sample with the same frequency and jstatic requires a datapoint for each. I’d also love to get more data involved, but the health kit request is pretty limited, I may export csv from my other apps and utilize that some day. Help/suggestions welcome; of course, otherwise why would I post it.