comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » xmargin and ymargin keywords ignored in cgplot
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
xmargin and ymargin keywords ignored in cgplot [message #86780] Tue, 03 December 2013 00:29 Go to next message
Xin Tao is currently offline  Xin Tao
Messages: 40
Registered: April 2011
Member
Hi all,

I just noticed that cgplot in David's coyote library doesn't seem to take xmargin and ymargin keywords. These keywords are not listed in the doc of cgplot, so I guess they are passed via " _REF_EXTRA=extra". Could someone please tell me how to make these two keywords effective? Thanks a lot.

Sample code:

cgplot, [0], xmargin = [10, 20]

produces a figure looks exactly the same as

cgplot, [0], xmargin = [10, 2]

but vastly different from

plot, [0], xmargin = [10, 2]



Best,

Xin Tao
Re: xmargin and ymargin keywords ignored in cgplot [message #86783 is a reply to message #86780] Tue, 03 December 2013 05:12 Go to previous messageGo to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Xin Tao writes:

> I just noticed that cgplot in David's coyote library doesn't seem to take xmargin and ymargin keywords. These keywords are not listed in the doc of cgplot, so I guess they are passed via " _REF_EXTRA=extra". Could someone please tell me how to make these two keywords effective?

I guess you can file this under the personal quirk category, but I don't
believe in margins. I believe in positioning things with the POSITION
keyword. The reason for this is that I know where things are going to go
when I use the Position keyword, since normalized units mean the same
thing everywhere. Margins are specified using *character* units and I
find them confounding and impossible to work with. You can't match up
different kinds of plots using them. You don't know where things are in
the window, etc. I find them a nightmare. It's the same reason you will
never find me using a TVSCL command. :-)

If you want to use them, you will have to find the section of code that
defines the default plot position and get rid of it. But, if you do, I
can practically guarantee you will run into other problems with Coyote
Graphics routines.

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
Sepore ma de ni thue. ("Perhaps thou speakest truth.")
Re: xmargin and ymargin keywords ignored in cgplot [message #86791 is a reply to message #86783] Tue, 03 December 2013 17:04 Go to previous message
Xin Tao is currently offline  Xin Tao
Messages: 40
Registered: April 2011
Member
Thanks David. I'll think about using POSITION instead of margins with cgplot. Don't want to break other routines of mine using CG. :-)

Best,

Xin Tao

On Tuesday, December 3, 2013 9:12:05 PM UTC+8, David Fanning wrote:
> Xin Tao writes:
>
>
>
>> I just noticed that cgplot in David's coyote library doesn't seem to take xmargin and ymargin keywords. These keywords are not listed in the doc of cgplot, so I guess they are passed via " _REF_EXTRA=extra". Could someone please tell me how to make these two keywords effective?
>
>
>
> I guess you can file this under the personal quirk category, but I don't
>
> believe in margins. I believe in positioning things with the POSITION
>
> keyword. The reason for this is that I know where things are going to go
>
> when I use the Position keyword, since normalized units mean the same
>
> thing everywhere. Margins are specified using *character* units and I
>
> find them confounding and impossible to work with. You can't match up
>
> different kinds of plots using them. You don't know where things are in
>
> the window, etc. I find them a nightmare. It's the same reason you will
>
> never find me using a TVSCL command. :-)
>
>
>
> If you want to use them, you will have to find the section of code that
>
> defines the default plot position and get rid of it. But, if you do, I
>
> can practically guarantee you will run into other problems with Coyote
>
> Graphics routines.
>
>
>
> Cheers,
>
>
>
> David
>
> --
>
> David Fanning, Ph.D.
>
> Fanning Software Consulting, Inc.
>
> Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
>
> Sepore ma de ni thue. ("Perhaps thou speakest truth.")
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Color Data with Colorbar OOB Colors
Next Topic: 3D VOLUME VISUALIZATION

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 11:54:03 PDT 2025

Total time taken to generate the page: 0.00567 seconds