Leah Huk
2013-04-11 20:04:30 UTC
Hello! I'm having a weird issue with the colors and thicknesses of vertical lines plotted using the very simple routine VLINE, written by John Johnson and found here: http://astro.berkeley.edu/~johnjohn/idlprocs/vline.pro.
I'm trying to use this routine to easily overplot markers for wavelengths of certain spectral lines over a spectra and into a .ps output file. It works, however, some of the lines appear grey and of greater thickness, with the exception of the bluest (left most) line. That one looks correct, thinner and black, despite it NOT being plotted first.
First, I tried using TVLCT (follwing your article on "Understanding IDL colors") to specify the RGB values for black and using the THICK keyword to specify thickness. This did not work. The left most line is still black and correct thickness, the others are greyish and thicker. Second thing I tried was to amend the VLINE routine to call cgOPlot instead of regular OPlot, and then called the colors in using the string name. Still doesn't work.
I am stumped. Anyone have any inkling as to why only one of my vertical lines will plot with the correct color/thickness while all the others will not?
ps_open,'filename'
cgDisplay,3000,900,/free
cgplot,x,y,title='title',xtitle='xname',ytitle='yname',color='red',thick=3
vline,6563,color='black',linestyle=0,thick=0.75
vline,4861,color='black',linestyle=0,thick=0.75 (this one looks correct)
vline,5876,color='black',linestyle=1,thick=0.75
vline,5017,color='black',linestyle=1,thick=0.75
ps_close
I'm trying to use this routine to easily overplot markers for wavelengths of certain spectral lines over a spectra and into a .ps output file. It works, however, some of the lines appear grey and of greater thickness, with the exception of the bluest (left most) line. That one looks correct, thinner and black, despite it NOT being plotted first.
First, I tried using TVLCT (follwing your article on "Understanding IDL colors") to specify the RGB values for black and using the THICK keyword to specify thickness. This did not work. The left most line is still black and correct thickness, the others are greyish and thicker. Second thing I tried was to amend the VLINE routine to call cgOPlot instead of regular OPlot, and then called the colors in using the string name. Still doesn't work.
I am stumped. Anyone have any inkling as to why only one of my vertical lines will plot with the correct color/thickness while all the others will not?
ps_open,'filename'
cgDisplay,3000,900,/free
cgplot,x,y,title='title',xtitle='xname',ytitle='yname',color='red',thick=3
vline,6563,color='black',linestyle=0,thick=0.75
vline,4861,color='black',linestyle=0,thick=0.75 (this one looks correct)
vline,5876,color='black',linestyle=1,thick=0.75
vline,5017,color='black',linestyle=1,thick=0.75
ps_close