Bill - does this help at all?  I show how to create a plot palette that has
a lower and an upper part.

Regards,

Devon

--------------------------------------------------------------------------------------------------------------------
   load 'viewmat plot'
stepsftn=:3 : 0
NB.* stepsftn: vector of numbers from num, to num, in numsteps steps.
   'from to numsteps'=. y
   from+(to-from)*(numsteps-1)%~i.numsteps
)

NB. Build palette from blue->green->yellow
   BGYPAL3=: ;stepsftn&.>0 60 30;62 80 30;80 100 26;102 140 85;142 210
43;220 255 42
   BGYPAL3=: BGYPAL3,:;stepsftn&.>0 100 55;102 140 30;142 224 86;228 255 85
   BGYPAL3=: BGYPAL3,;stepsftn&.>0 255 45;250 88 116;86 130 44;132 200 51
   BGYPAL3=: roundNums |:BGYPAL3

NB. Look at the palette
   BGYPAL3 viewmat i. 16 16

NB. Build palette half from previous one, second half: dark
green->pink->pale pink
   PAL2=. (BGYPAL3#~256$1 0),(1|."1 BGYPAL3)#~256$1 0
NB. Look at the palette
   PAL2 viewmat i. 16 16
NB. Use this palette with "plot".
   RGCLR_jwplot_=: PAL2
   'surface' plot +/~1 o. i:6j99


On Fri, Mar 13, 2009 at 12:49 AM, Bill Harris <
[email protected]> wrote:

> I'm trying to do a surface plot with a 7 by 5 array (or something like
> that).  I'd like to have a 3x5 field that's drawn from one color family
> and a 4x5 field that's from another color family.
>
> As best as I can tell, the color is only related to the height along the
> Z axis.  Is there an easy way to create such a diagram with each row (or
> column) in a color family I select, perhaps with the intensity of the
> colors related to the height?  (Using the Brewer series might be
> interesting eventually but not necessary right now; right now, I need to
> pick the color family.)
>
> Oh, and can I make the color rows go either way?  I presume |: is the key.
>
> Thanks,
>
> Bill
> --
> Bill Harris                      http://facilitatedsystems.com/weblog/
> Facilitated Systems                              Everett, WA 98208 USA
> http://facilitatedsystems.com/                  phone: +1 425 337-5541
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>



-- 
Devon McCormick, CFA
^me^ at acm.
org is my
preferred e-mail
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to