Friday, February 26, 2010

New colors in SM

I like to use Super Mongo to make my plots. It is a very nice software, but somethings are, some times, hard to do (or hard to find in the tutorial). My last 3 problems were related to:

a) Log scales in SM.

All what you need to do is:

: ticksize -1 0 -1 0
: box

Note: you need to work with the data in log, what you can do by:

: read {f1 1}
: set f1=lg(f1)

b) Add grid lines in the plot.

: box grid 1 (to small and long grid lines) or 0 (for only long grid).

c) The last one was in trying to add more colors to SM color pallet.
To solve this issue I found Annika Peter page, which  I resume below.

Note: The figures were taken from Annika Peter page.

The problem: There are only seven "default" colors in SM.

But is very easy to add more colors to SM color pallet.
i) use the command "add_ctype"

: add_ctype mycolor 170 170 0   

This will produce darkgold

A very nice tool to help here is the web site.

ii) Use the : xtcolors to add new colors. This will produce the following colors.

I hope this will help you.

No comments:

Post a Comment

Locations of visitors to this page