Use leasqr.m in octave to fit data with error
higgs
nguyenoh at yahoo.com
Wed Apr 8 13:12:15 CDT 2009
Thank you very much for your confirmation.
If it is familiar to you, could you please tell how can I extract
"Chi-squared/ Number of Degree of freedom" from the program. Is there some
option or I have to code it my own?
Best Regards,
Francesco Potorti`-2 wrote:
>
>>I have a data file looks like,
>>
>>data = [
>> 10 1684.023253675213 142923.5184171736
>> 11 1154.101457435897 79000.44034169338
>> 12 793.8254991880336 44430.77751038589
>> 13 548.7675124786326 24452.17758038106
>>...]
>>
>>where the first column are variable values, the second one are data values
>>and the third one are corresponding errors of data on second column.
>>
>>I've used function leasqr.m to fit these data to some analytic function.
It
>>seems to work well but I'm still wondering that I've done right things
with
>>inputs. My question is:
>>Is it correct to set variable "wt" of the function equal to the inverse of
>>error: wt = 1./data(:,3)
>
> Yes, it is, as far as I know.
>
> --
> Francesco Potortì (ricercatore) Voice: +39 050 315 3058 (op.2111)
> ISTI - Area della ricerca CNR Fax: +39 050 315 2040
> via G. Moruzzi 1, I-56124 Pisa Email: Potorti at isti.cnr.it
> (entrance 20, 1st floor, room C71) Web: http://fly.isti.cnr.it/
> _______________________________________________
> Help-octave mailing list
> Help-octave at octave.org
> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave
>
>
--
View this message in context: http://www.nabble.com/Use-leasqr.m-in-octave-to-fit-data-with-error-tp22937226p22956506.html
Sent from the Octave - General mailing list archive at Nabble.com.
More information about the Help-octave
mailing list