Student Support Forum
-----
Student Support Forum: 'change the range of ColorData' topicStudent Support Forum > General > Archives > "change the range of ColorData"

< Previous Comment | Next Comment >Help | Reply To Comment | Reply To Topic | Post New Topic
Author Comment/Response
Forum Moderator
email me
07/06/08 12:10pm

Unless I misunderstand, you do not have to do anything. The value sent to the color function is scaled to the range {0,1} where the min of what you are plotting is mapped to 0 and the max to 1. Here is some sample data:

datavz = Table[
With[{r = RandomReal[{0, 10}],
t = RandomReal[{0, 2 Pi}]}, {r Cos[t], r Sin[t],
r Sin[t]}], {10^2}];

A surface plot shows the shape of the data.

ListSurfacePlot3D[datavz, PlotRange -> All]

In the density plot the gradient of color goes from dark to light as the value plotted goes from -10 to 10.

ListDensityPlot[datavz, ColorFunction -> "GrayTones"]

If you are looking for something else, you might post a more specific example with a small data sample.

Tom Zeller



URL: ,

Subject (listing for 'change the range of ColorData')
Author Date Posted
change the range of ColorData Florent 07/03/08 3:04pm
Re: change the range of ColorData Forum Modera... 07/06/08 12:10pm
Re: Re: change the range of ColorData Florent 07/06/08 4:41pm
Re: change the range of ColorData Forum Modera... 07/06/08 8:55pm
Re: Re: change the range of ColorData Florent 07/07/08 11:35am
< Previous Comment | Next Comment >Help | Reply To Comment | Reply To Topic | Post New Topic





 © 2008 Wolfram Research, Inc.  Terms of Use  Privacy Policy |
Sign up for our newsletter: