see TH2::Interpolate
Rene
On 11/02/2011 22:27, nguler_at_jlab.org wrote:
> I am using root version 5.26-00-64bit, but I will very soon switch to 5.28.
> Actually I could not try TH2F::Eval because I could not see that class. I get
> compilation error when I try to use it like:
> histo2D->Eval(0,25)
> where I have defined
> TH2F *histo2D = new TH2F("histo2D","histo2D ",66,-400,400,66,-400,400);
> So should I think TH2F does not support Eval class..?
>
> I instead fitted the histo2D with some TF2 function:
> TF2 *twodFit2 = new TF2("twodFit2",TwoDFit2,-400,400, -400,400,17);
> and used
> twodFit2->Eval(0,25);
> But this is of course not what I want. I want to skip the fitting part since I
> don't trust enough the functional form and directly interpolate the data. But
> I want to use the best interpolation scheme that already exists in root
> instead of writing a new interpolation routine. Does that leave me to only
> TGraph2d::Interpolate class since there is not TH2F::Eval class?
>
> Thanks for your suggestions.
> - Nevzat
>
>
>> Did you try both TGraph2D::Interpolate and TH2::Eval?
>>
>> Note that some optimizations in TGraph2D::Interpolate were done in
>> version 5.28
>>
>> Rene Brun
>>
>>
>> On 11/02/2011 04:31, nguler_at_jlab.org wrote:
>>> Hello All,
>>> I have an intensity distribution in x and y dimensions. The distribution is
>>> discrete but I am plotting it with TGraph2D and then using Interpolate class
>>> to get the value of the intensity for (x,y) point that is not in the
>>> original
>>> data. It is not too far off but not perfect either. I am wondering if there
>>> is
>>> any other class that I am not aware of. I would like to try and compare. Is
>>> there Eval class (like the one for TH2F) for TGraph2D?
>>>
>>> Is the Eval class for TH2F better than the Interpolate class for TGraph2D
>>> for
>>> this kind of thing, so should I fill a histogram instead of filling
>>> TGraph2D?
>>>
>>> I appreciate you comments.
>>>
>>> - Nevzat Guler
>>> (757) 553-8318
>>>
> - Nevzat Guler
> (757) 553-8318
>
Received on Sat Feb 12 2011 - 09:55:43 CET
This archive was generated by hypermail 2.2.0 : Sun Feb 13 2011 - 23:50:01 CET