Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: RE: writing quotes in a global variable


From   Nick Cox <[email protected]>
To   "'[email protected]'" <[email protected]>
Subject   st: RE: writing quotes in a global variable
Date   Thu, 23 Jun 2011 12:31:39 +0100

You don't need the outermost quotation marks " " to define a global macro. Try 


. global mycolor lcolor("100 100 100")

. mac li 

However, 

1. Stata does not use the terminology of global variables: see e.g. 

http://www.stata.com/statalist/archive/2008-08/msg01258.html 

2. Your definition looks very confused: there are two commas and the single quotation marks are not balanced and there is an odd character there, so the chance of this working as you intend is zero. 

It is best not to try to run before you are able to walk! 

Nick 
[email protected] 

Martin Albers

I have a problem. I want to use RGB colors for graphics, because I need 60
discriminable colors. For this I have to code the colors "# # #". My problem
is that I cannot write Quotes into global variables. Is there any way or
trick to do so?

I need a global variable of the type
global graph1 "connected `op'ì'' `t', sort, lcolor("100 100 100")"

or

global color105 "100 100 100" 

where the quotes are part of the global variable, because otherwise I cannot
specify RGB-Colors.


*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index