The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum for Programming
 LabTalk Forum
 colors in contour plots

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
letay@ise.1 Posted - 06/27/2002 : 12:39:00 PM
Hi everybody,

I am trying to generated a contour plot from a matrix by a labtalk script.
The problem is, that I can not set the zvalues and the color as needed.
I tried two ways:
1) I setup my plot with the desired colorabove, high, low, missing values as needed, saved it to a template and than used this template to generate the contour plot. unfortunately it seems so, that the color settings (layer.cmap....) are not stored in the template. They are reseted to the default values.

2) I tried to set the cmap values my self with layer.cmap.low... One thing is that zmax and zmin only set the first and last value of the scale but do not modify the values between the limits. the same is true for colorhigh and colorlow. they also only modify the highest and lowest value but not the whole scale. I tried several execution orders of the cmap-commands but each time cmap.numcolors is executed all other settings are reseted to their default values!?!

3) I can set all z and color values by hand with a nice for loop like this:

for(i=0;i<=LAYER.CMAP.NUMCOLORS;i+=1){
LAYER.CMAP.Z$(i+1) = LAYER.CMAP.ZMAX-(LAYER.CMAP.ZMAX-LAYER.CMAP.ZMIN)/LAYER.CMAP.NUMCOLORS*i
};

but how can I generate a rainbow color from blue to red?

Anyone who fixed this problem?

regards
gergoe letay

P.S.: I am running Origin 6.1R4 german version on Win2000
 
1   L A T E S T    R E P L I E S    (Newest First)
Laurie Posted - 06/28/2002 : 08:56:17 AM
When saving a contour plot, the levels (color map) are not saved because these updatae when you plot new data.

Create the graph and set the levels the way you want, then run the following LabTalk command:

layer -cm s filename;

to save these settings to a file with the name, filename.

Now create a new plot, and use layer -cm l filename; //load

OriginLab Technical Support

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000