Home »
Public Forums »
archive »
LEGEND and Symcat - part 2
LEGEND and Symcat - part 2 [message #70975] |
Tue, 18 May 2010 05:54 |
Mrunmayee
Messages: 24 Registered: May 2009
|
Junior Member |
|
|
So, I did go through previous posts since I also encountered the
problem. Problem is that if you use Symcat to draw plot symbols, there
isn't a way to get them into LEGEND - the routine as it came with the
library (as of 2008). It will only plot the last symbol you used. So,
in the previous thread (http://groups.google.com/group/comp.lang.idl-
pvwave/browse_thread/thread/c7c8a10fd1611c73/2930e1bf2b34450 7) a
solution was suggested by David and implemented by Wayne which makes
the LEGEND call Symcat if psym > 8. (Also takes care of psym=10
errors.) I downloaded the modified program that Wayne has given link
to in the above thread.
What it doesn't do right is plotting legend with e.g. psym=-16. That
is the symbols connected by line. Because Symcat accepts only positive
psym values. Solution is a no brainer actually, but here it is for
anyone to use. Instead of the following line (line 425 in the routine
from the link in above thread):
else if psym[i] GT 8 then p_sym = symcat(psym[i]) else p_sym= psym[i]
I wrote this:
else if abs(psym[i]) GT 8 then begin
abs_psym = abs(psym[i])
sign = abs_psym/psym[i]
p_sym = sign*symcat(abs_psym)
endif else p_sym= psym[i]
Now this plots Symcat's symbols connected by line if so required.
|
|
|
Current Time: Fri Oct 10 20:18:50 PDT 2025
Total time taken to generate the page: 0.87952 seconds