Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


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

st: how to set colors in a .scheme file using -colorstyle- syntax


From   Paolo Bonaiuti <paolo.bonaiuti@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: how to set colors in a .scheme file using -colorstyle- syntax
Date   Wed, 20 Jun 2012 15:58:58 +0200

dear statalisters,
first of all: thanks everybody for your work here: I use your answers
since my first day with Stata, and they've been really helpful.

then, the question.
overview:
i am a Stata 9.2/SE, Windows XP/Professional user.
I'm producing lots of survival graphs using -sts graph- or -ltable,
graph-, and I use many times the same -by- options.
I would like my graphs to use the same colors when the same variable
is in the -by-.

since -ltable- and -sts graph- seem to have different syntax for
colors, I decided to make a scheme, called -age-, to be used as
-ltable timevar eventvar, graph scheme(age)- and so on.

The scheme sounds like this:
-------------------------------------- scheme-age.scheme ----------------------
#include s2color

color p1      teal
color p2      teal*.8
color p3      teal*.6
color p4   and so on..
-----------------------------------------------------

since there are so many graphs to be drawn, I want my colors to be the
same but with different intensity, so I'm not going to end up all the
available colors with a name.

the problem:
the syntax -colorname*intensity- does not work in a scheme file!

I tried with rgb syntax (namely: color p1  "110 142 132") and it
works, butwhen I add the instensity multiplicator it stops working.
I'd appreciate also to use the CMYK syntax, so I can change the
brightness with the blacK factor, but I don't know how to tell my
-scheme- to use CMYK syntax.


I hope the problem is clear.
Could anybody help me?

Thanks in advance,

Paolo Bonaiuti
*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index