Re: IDL issues: poly_fit.pro. [message #83943] |
Wed, 17 April 2013 11:33  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Sreelakshmi S writes:
> I have defined the path as you have said.
>
> export IDL_PATH=$IDL_PATH:'+~/idlastrosoftware'
>
> My operating system is Ubuntu
Well, if that is where POLY_FIT program is, then you are good to go. The
POLY_FIT I know about doesn't live in the Astronomy Library, but in the
IDL library. So, in my case, this wouldn't help much. You may have
better results. :-)
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thue. ("Perhaps thou speakest truth.")
|
|
|
|
|
Re: IDL issues: poly_fit.pro. [message #83946 is a reply to message #83945] |
Wed, 17 April 2013 10:42   |
Sreelakshmi S
Messages: 8 Registered: April 2013
|
Junior Member |
|
|
On Wednesday, April 17, 2013 8:27:45 PM UTC+5:30, David Fanning wrote:
> Sreelakshmi S writes:
>
>
>
>> fit=poly_fit(x,y,fit)
>
>> both x any y are arrays
>
>
>
> OK, well, I think IDL has gotten confused for some reason. What happens
>
> if you try this command after compiling POLY_FIT?
>
>
>
> IDL> .compile poly_fit
>
> IDL> fit=poly_fit(x,y,fit)
>
>
>
> Cheers,
>
>
>
> David
>
>
>
>
>
> Its showing error opening file. File:poly_fit
>
> --
>
> David Fanning, Ph.D.
>
> Fanning Software Consulting, Inc.
>
> Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
>
> Sepore ma de ni thue. ("Perhaps thou speakest truth.")
|
|
|
Re: IDL issues: poly_fit.pro. [message #83951 is a reply to message #83946] |
Wed, 17 April 2013 07:57   |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Sreelakshmi S writes:
> fit=poly_fit(x,y,fit)
> both x any y are arrays
OK, well, I think IDL has gotten confused for some reason. What happens
if you try this command after compiling POLY_FIT?
IDL> .compile poly_fit
IDL> fit=poly_fit(x,y,fit)
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thue. ("Perhaps thou speakest truth.")
|
|
|
|
|
Re: IDL issues: poly_fit.pro. [message #84026 is a reply to message #83952] |
Tue, 23 April 2013 09:13  |
Norbert Hahn
Messages: 46 Registered: May 2003
|
Member |
|
|
Sreelakshmi S <sreelakshmi.s86@gmail.com> wrote:
> fit=poly_fit(x,y,fit)
> both x any y are arrays
... and how is the variable fit (3rd parameter) defined?
It will be overridden by the result of poly_fit. Is that what you want?
The documentation says:
; CALLING SEQUENCE:
; Result = POLY_FIT(X, Y, Degree)
;
; INPUTS:
; X: The independent variable vector.
;
; Y: The dependent variable vector, should be same length as x.
;
; Degree: The degree of the polynomial to fit.
;
; OUTPUTS:
; POLY_FIT returns a vector of coefficients with a length of NDegree+1.
;
Norbert
|
|
|
Re: IDL issues: poly_fit.pro. [message #84028 is a reply to message #83943] |
Tue, 23 April 2013 07:09  |
Sreelakshmi S
Messages: 8 Registered: April 2013
|
Junior Member |
|
|
On Thursday, April 18, 2013 12:03:50 AM UTC+5:30, David Fanning wrote:
> Sreelakshmi S writes:
>
>
>
>> I have defined the path as you have said.
>
>>
>
>> export IDL_PATH=$IDL_PATH:'+~/idlastrosoftware'
>
>>
>
>> My operating system is Ubuntu
>
>
>
> Well, if that is where POLY_FIT program is, then you are good to go. The
>
> POLY_FIT I know about doesn't live in the Astronomy Library, but in the
>
> IDL library. So, in my case, this wouldn't help much. You may have
>
> better results. :-)
>
>
>
> Cheers,
>
>
>
> David
>
>
>
>
>
> So how should I modify so that it reads from both libraries?
>
> --
>
> David Fanning, Ph.D.
>
> Fanning Software Consulting, Inc.
>
> Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
>
> Sepore ma de ni thue. ("Perhaps thou speakest truth.")
|
|
|