comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Hello
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Hello [message #91412 is a reply to message #91401] Fri, 10 July 2015 11:45 Go to previous messageGo to previous message
Jeremy Bailin is currently offline  Jeremy Bailin
Messages: 618
Registered: April 2008
Senior Member
On Thursday, July 9, 2015 at 11:14:12 AM UTC-4, hana3...@gmail.com wrote:
> Hello there,
>
> I'm a new totally in Idl. So, I need your help
>
> Actually, I've plotted two axis, consisting of x-axis which represents color index ( e.g. r-i) and y-axis which represents magnitude (e.g. r) and inside the plot, there is objects (stars) lie in the models which represents log (g) ( g surface gravity ranging from 7.0 to 9.5) and stars lie between them. Now, I need to estimate logg for each stars and I have written the code. Unfortunately, my code does not work.
>
> This my code,
>
> x=fltarr(r-i) ; x-axis
> y=fltarr(r) ; y-axis
> xx=findgen(6)/20-0.72 ; logg
>
> n=0
> while n lt number_of_wd do begin
> j=0
> while j lt number_of_stars do begin
> linterp,x,y,xx,yy
> endif
> j=j+1
> endwhile
> n=n+1
> endwhile
> print,transpose(yy)
> end
>
> I'm waiting your suggestions and your help (Please help me)
>
> thanks
> Hana

Look at your definitions of x and y.

FLTARR creates a new array of length its argument that initially contains zeros. I don't think that's what you want -- perhaps you just want:

x = r-i
y = r

-Jeremy.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: to convert 3d array to 2d array
Next Topic: IDLWAVE and &$ blocks

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 17:10:07 PDT 2025

Total time taken to generate the page: 0.00498 seconds