# Change time graph duration based on context

**URL:** <https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905>\
**Category:** Feature Request\
**Tags:** time-series\
**Created:** [June 20, 2019, 3:06pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905 "2019-06-20T15:06:05Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![paul\_wareham](https://avatars.discourse-cdn.com/v4/letter/p/ed8c4c/32.png) [@paul\_wareham](https://forums.losant.com/u/paul_wareham)\
**Post date:** [June 20, 2019, 3:06pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/1 "2019-06-20T15:06:06Z")

</div>

It would be great to be able to change the default duration for a time series graph based on the value of a context variable. We have situations where the device may be offline and the customer would like to see a longer timescale by default without having to manually change it.

---

<div class="post-metadata">

**Author:** ![JuliaKempf](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/juliakempf/32/2446_2.png) [@JuliaKempf](https://forums.losant.com/u/JuliaKempf)\
**Post date:** [June 20, 2019, 3:11pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/2 "2019-06-20T15:11:45Z")

</div>

Hi Paul,

I will create a feature request with our engineers and let you know if it is selected for development!

Thanks,  
Julia

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [April 13, 2020, 2:48pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/3 "2020-04-13T14:48:33Z")

</div>

any updates on this?

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [April 13, 2020, 3:01pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/7 "2020-04-13T15:01:47Z")

</div>

The reason me asking is that I have an application where I record a certain start/stop time depending on some time series changes and present those as rows in a custom html table.  
I would like to make a link of each row to show a time series graph with the duration being those previously recorded start and stop times.  
Shouldn’t I be able to do this?

---

<div class="post-metadata">

**Author:** ![JuliaKempf](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/juliakempf/32/2446_2.png) [@JuliaKempf](https://forums.losant.com/u/JuliaKempf)\
**Post date:** [April 13, 2020, 5:33pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/9 "2020-04-13T17:33:12Z")

</div>

Hi @Lars_Andersson,

This Feature Request has not yet been implemented, but I will keep you updated on the status.

You could make use of the `t` query parameter in order to create a link within your Custom HTML Block, but you’ll have to determine the logic for the timestamp within the block. For example, to view the dashboard 60 minutes ago, my dashboard link would be `https://app.losant.com/dashboards/5ddd4e44fxxx?t=1586794726137`.

Thanks!  
Julia

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [April 13, 2020, 6:40pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/11 "2020-04-13T18:40:56Z")

</div>

but the t parameter can only define where to start showing the graph from? not where to end it?

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [May 7, 2020, 7:55pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/15 "2020-05-07T19:55:21Z")

</div>

is there not a variable for when to end the graph?

---

<div class="post-metadata">

**Author:** ![anaptfox](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/anaptfox/32/873_2.png) [@anaptfox](https://forums.losant.com/u/anaptfox)\
**Post date:** [May 7, 2020, 7:56pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/18 "2020-05-07T19:56:28Z")

</div>

@Lars_Andersson,

No, our visualizations are based on a time and duration, not start and end time.

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [May 7, 2020, 8:12pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/19 "2020-05-07T20:12:22Z")

</div>

ok, so if there is a t variable for time, is there a d variable for duration?

---

<div class="post-metadata">

**Author:** ![anaptfox](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/anaptfox/32/873_2.png) [@anaptfox](https://forums.losant.com/u/anaptfox)\
**Post date:** [May 8, 2020, 1:15pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/22 "2020-05-08T13:15:50Z")

</div>

@Lars_Andersson,

Currently, the only option today is time. However, their are tickets to make some improvements in this area. I just +1 it for you and let you know if anything happens.

---

<div class="post-metadata">

**Author:** ![Lars\_Andersson](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@Lars\_Andersson](https://forums.losant.com/u/Lars_Andersson)\
**Post date:** [September 8, 2021, 2:45pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/23 "2021-09-08T14:45:17Z")

</div>

Any updates on this topic here ?

---

<div class="post-metadata">

**Author:** ![Heath](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/heath/32/3036_2.png) [@Heath](https://forums.losant.com/u/Heath)\
**Post date:** [September 8, 2021, 3:11pm UTC](https://forums.losant.com/t/change-time-graph-duration-based-on-context/1905/25 "2021-09-08T15:11:10Z")

</div>

Hey Lars,

I don’t have an update for you. I will, though, bump this ticket for you again and follow up with you with what I learn about it.

Thank you,  
Heath
