Libraries‎ > ‎orbits‎ > ‎

Set plot range

BehaviourComposer: ignore everything before this.

Begin micro-behaviour:

Begin description:

sets the maximum and minimum of the graph to appropriate value from the body properties.

End description

Set plot range 

Begin NetLogo code:

substitute-text-area-for range-extension .5
set-current-plot (word kind " Distances")
set-plot-x-range 0 precision ( my-length-of-year-in-seconds / time-scale ) 3
let full-range (my-maximum-distance-to-com - my-minimum-distance-to-com)
let extension (full-range * range-extension) 
set-plot-y-range precision (my-minimum-distance-to-com - extension ) -3 
                 precision (my-maximum-distance-to-com + extension ) -3

End NetLogo code

Authored by Maria Marinari and Ken Kahn. Updated 16 January 2017 because 'range' is not part of NetLogo 6.0

BehaviourComposer: ignore everything after this.