Re: setrange of x-axis

From: Tim Head <betatim_at_gmail.com>
Date: Thu, 21 Jul 2011 11:54:10 +0000


On Thu, Jul 21, 2011 at 8:20 AM, Olivier Couet <Olivier.Couet_at_cern.ch> wrote:
> The doc says that SetLimits defines the limit of the axis (min and max),
> whereas SetRange and SetRangeUser define the viewing range within these
> limits. I do not see what you could says more ?
> Any suggestions ?

At the very least the SetLimits() docs should explicitly state that this function does _not_ do what 90% of users expect it to do (which is to determine the range of the axis shown when drawn) [1]. Especially as it appears in the docs before the more obscurely named functions SetRange() and SetRangeUser().

Tim

[1] What does it even mean to limit the range of an axis if not for plotting purposes? Particularly for a TGraph which you pass all the points it will ever know about when you first create it.

>
> On 7/20/11 2:43 PM, "Philip Rodrigues" <p.rodrigues1_at_physics.ox.ac.uk>
> wrote:
>
>>It would be useful if the documentation of TAxis::SetLimits could be made
>>a
>>bit clearer - at the moment it's not obvious how it differs from
>>SetRangeUser.
>>
>>Cheers,
>>Phil
>>
>>On Wednesday, July 20, 2011 07:01:15 AM Olivier Couet wrote:
>>> See: http://root.cern.ch/drupal/content/how-set-ranges-axis
>>>
>>> From: Summit Kumar
>>> <rhythm4summit_at_gmail.com<mailto:rhythm4summit_at_gmail.com>> Date: Wed,
>>20
>>> Jul 2011 16:29:38 +0530
>>> To: <roottalk_at_root.cern.ch<mailto:roottalk_at_root.cern.ch>>
>>> Subject: [ROOT] setrange of x-axis
>>>
>>> Hello Rooters,
>>>
>>>
>>> I have caught in very simple problem. I have plotted a graph by using
>>> TGraph. I want to know how can I enlarge x-axis.within certain limits?
>>>
>>>
>>> --
>>> THANKS
>>> With regards,
>>>
>>> Summit.
>>
>
>

-- 
http://tim.jottit.com/
Received on Thu Jul 21 2011 - 13:54:24 CEST

This archive was generated by hypermail 2.2.0 : Thu Jul 21 2011 - 17:50:02 CEST