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
 creating vertical line at plot maximum

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
benderrr Posted - 07/19/2005 : 3:37:51 PM
Origin Version (Select Help-->About Origin): 7.5
Operating System: WinXP
Hello,
I have got some hundreds of graphs to do and a lot of work in front of me. I would like to add a vertical dashed line on each graph between the top and bottom x-axis. The vertical line shall serve to help to relate sets of graphs with the same x-axis, but different plot contents to each other. The vertical line shall pe plotted at the x-position, where one special column has its maximum.
Can you help me out with something I could use in the script window? It would be already very helpful to have a script that plots a vertical dashed grey line at a special x-position ranging from top to bottom x-axis.
Maybe it is possible to plot this line as a linear function of type y = xposition and to add the grey dashed style to it? I just do not know how to perform this as a script..
Thanks for your help,
Bender

4   L A T E S T    R E P L I E S    (Newest First)
greg Posted - 07/26/2005 : 2:20:17 PM
If you name the object when created you can then set the color :

draw -n Mark1 -w 0.5 -d 1 -l -v 5;
Mark1.color=2;

So programmatically ...

NextMark = 1;
...
...
draw -n Mark$(NextMark) -w 0.5 -d 1 -l -v 5;
Mark$(NextMark).color=2;
NextMark++;
...
...


easwar Posted - 07/19/2005 : 5:28:05 PM
Hi Bender,

The -c option for color does not work as you found out.

For now you could do the following.
Any object such as the line you create has a name. The first line you add to a layer has default name Line, the next has name Line1 etc.

So you can add another line to your code to change color such as:
draw -w 0.5 -d 3 -l -v 3;
line.color=3;

Easwar
OriginLab

benderrr Posted - 07/19/2005 : 5:01:57 PM
Hi Mike,
thank you for the hint. I searched the LabTalk language reference because additionally I'd like to set the line's color, and it says to use the -c # option on draw.
"# equals the numeric position in the color list starting with zero (black = 0, red = 1, green = 2, etc.). "

However, no matter which number I use, for example

draw -c 2 -w 0.5 -d 3 -l -v 3;

the line is still black. Do I have to define a color listing before somewhere?
Best Regards,
Bender
Mike Buess Posted - 07/19/2005 : 3:56:20 PM
Hi Bender,

Use LabTalk's draw command. I think the following will do what you want but check the programming guide for details.

draw -w 0.5 -d 1 -l -v X-position;

-l -v X-position >> draws a vertical line from top to bottom at X=X-position
-d 1 >> sets the line pattern to dash
-w 0.5 >> sets the line width to 0.5 (so you can see the dashes)

Mike Buess
Origin WebRing Member

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