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
 Origin Forum
 problem with 2D contour plot

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
sanjinwx Posted - 01/18/2007 : 08:31:22 AM
Origin Version (Select Help-->About Origin): 7.5
Operating System:WINDOWS XP

For the 2D contour plot, normally a square picture can be got. If the dimensions of X and Y are not the same,the unit scales of X and Y which represent the real length will not be the same.
But now I want to get a plot with same unit scale of X and Y, which means a rectangular picture will be get.
I really do not how to do this, is there somebody who can help me?
Thanks a lot.

3   L A T E S T    R E P L I E S    (Newest First)
Laurie Posted - 01/18/2007 : 2:03:12 PM
Please copy all lines of script and paste to the Script Window. Please do not modify the script, but simply highlight the entire block (all lines) and press Enter to execute. If you do this, I can't think of a reason why you'd get a command error.

Please let me know what happens.

Thank you,
Laurie
OriginLab Technical Support
sanjinwx Posted - 01/18/2007 : 10:24:22 AM
sorry,I have tried,but ´´#Command Error!´´
easwar Posted - 01/18/2007 : 09:32:53 AM
Hi,

With the contour graph window active, bring up the Script Window and then copy-paste the lines of script shown below. Then select all the lines and press enter to execute the script.

Easwar
OriginLab


oldunit=layer.unit;
layer.unit = 2;
dwidth = x2 - x1;
dheight = y2 - y1;
if(dwidth/dheight > 1)
{
layer.height = layer.width * dheight / dwidth;
}
else
{
layer.width = layer.height * dwidth / dheight;
}
layer.unit=oldunit;



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